Installation
npm install --save @types/fps
Summary
This package contains type definitions for fps (https://github.com/hughsk/fps).
Details
Files were exported from https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/fps.
index.d.ts
export as namespace fps;
interface FPSOptions {
/** How many frames to tick before emitting. Defaults to 1. */
decay?: number;
/** The rate of change between old and new results. 1 is instantaneous, 0 is never. */
every?: number;
}
interface FPSObject {
tick: () => void;
on: (event: "data", callback: (frames: number) => void) => void;
last: number;
rate: number;
time: number;
decay: number;
every: number;
ticks: number;
}
declare function fps(options?: FPSOptions): FPSObject;
export = fps;
Additional Details
- Last updated: Tue, 07 Nov 2023 03:09:37 GMT
- Dependencies: none
Credits
These definitions were written by LeoDog896.