useFps ​
Reactive FPS (frames per second).
Demo ​
FPS: 0
Usage ​
js
import { useFps } from '@vueuse/core'
const fps = useFps()
Type Declarations ​
typescript
export interface UseFpsOptions {
/**
* Calculate the FPS on every x frames.
* @default 10
*/
every?: number
}
export declare function useFps(options?: UseFpsOptions): Ref<number>
Source ​
Contributors ​
Anthony Fu
webfansplz
jelf
Changelog ​
v12.0.0-beta.1
on 11/21/2024