@types/stats.js
TypeScript definitions for Stats.js
Last updated 8 years ago by types .
MIT · Repository · Original npm · Tarball · package.json
$ cnpm install @types/stats.js 
SYNC missed versions from official npm registry.

Installation

npm install --save @types/stats.js

Summary

This package contains type definitions for stats.js (https://github.com/mrdoob/stats.js).

Details

Files were exported from https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/stats.js.

index.d.ts

declare class Stats {
    constructor();

    REVISION: number;
    dom: HTMLDivElement;

    addPanel(panel: Stats.Panel): Stats.Panel;

    /**
     * @param value 0:fps, 1: ms, 2: mb, 3+: custom
     */
    showPanel(value: number): void;

    begin(): void;
    end(): number;
    update(): void;

    // Backwards Compatibility

    /**
     * @deprecated Use `dom` instead.
     */
    domElement: HTMLDivElement;

    /**
     * @deprecated Use `showPanel` instead.
     */
    setMode(value: number): void;
}

declare namespace Stats {
    class Panel {
        constructor(name: string, foregroundColor: string, backgroundColor: string);
        dom: HTMLCanvasElement;
        update(value: number, maxValue: number): void;
    }
}

declare module "stats.js" {
    export = Stats;
}

Additional Details

  • Last updated: Mon, 05 May 2025 20:35:19 GMT
  • Dependencies: none

Credits

These definitions were written by Gregory Dalton, Harm Berntsen, and Dan Vanderkam.

Current Tags

  • 0.17.0                                ...           latest (8 years ago)
  • 0.17.0                                ...           ts2.0 (8 years ago)
  • 0.17.0                                ...           ts2.1 (8 years ago)
  • 0.17.0                                ...           ts2.2 (8 years ago)
  • 0.17.0                                ...           ts2.3 (8 years ago)
  • 0.17.0                                ...           ts2.4 (8 years ago)
  • 0.17.0                                ...           ts2.5 (8 years ago)
  • 0.17.0                                ...           ts2.6 (8 years ago)
  • 0.17.0                                ...           ts2.7 (8 years ago)
  • 0.17.0                                ...           ts2.8 (8 years ago)
  • 0.17.0                                ...           ts2.9 (8 years ago)
  • 0.17.0                                ...           ts3.0 (8 years ago)
  • 0.17.0                                ...           ts3.1 (8 years ago)
  • 0.17.0                                ...           ts3.2 (8 years ago)
  • 0.17.0                                ...           ts3.3 (8 years ago)
  • 0.17.0                                ...           ts3.4 (8 years ago)
  • 0.17.0                                ...           ts3.5 (8 years ago)
  • 0.17.0                                ...           ts3.6 (8 years ago)
  • 0.17.0                                ...           ts3.7 (8 years ago)
  • 0.17.0                                ...           ts3.8 (8 years ago)
  • 0.17.0                                ...           ts3.9 (8 years ago)
  • 0.17.0                                ...           ts4.0 (8 years ago)
  • 0.17.0                                ...           ts4.1 (8 years ago)
  • 0.17.0                                ...           ts4.2 (8 years ago)
  • 0.17.0                                ...           ts4.3 (8 years ago)
  • 0.17.0                                ...           ts4.4 (8 years ago)
  • 0.17.0                                ...           ts4.5 (8 years ago)
  • 0.17.0                                ...           ts4.6 (8 years ago)
  • 0.17.0                                ...           ts4.7 (8 years ago)
  • 0.17.0                                ...           ts4.8 (8 years ago)
  • 0.17.0                                ...           ts4.9 (8 years ago)
  • 0.17.0                                ...           ts5.0 (8 years ago)

3 Versions

  • 0.17.0                                ...           8 years ago
  • 0.16.1                                ...           9 years ago
  • 0.16.0                                ...           9 years ago
Maintainers (1)
Downloads
Today 0
This Week 0
This Month 1
Last Day 0
Last Week 1
Last Month 0
Dependencies (0)
None
Dev Dependencies (0)
None
Dependents (1)

Copyright 2013 - present © cnpmjs.org | Home |