Nuclear Pumpkin Mocha

    whenever-ready
    TypeScript icon, indicating that this package has built-in type declarations

    1.1.0 • Public • Published

    Whenever ready Travis CI Build Status

    A promise that resolves when a value is set.

    NPM Badge

    Install

    npm install whenever-ready

    Usage

    const WheneverReady = require("whenever-ready");
    const wReady = new WheneverReady();
     
    wReady.when().then(() => console.log("READY!")); // Listen for readiness.
    wReady.ready = true; // Set as ready.

    API

    class WheneverReady(ready?)

    ready

    Type: boolean
    Default: false

    The initial readiness value.

    instance WheneverReady

    ready

    Type: boolean
    Default: false

    The readiness.

    when()

    Returns: Promise

    Returns a promise that will resolve when ready is true.

    Install

    npm i whenever-ready

    DownloadsWeekly Downloads

    12

    Version

    1.1.0

    License

    MIT

    Unpacked Size

    3.75 kB

    Total Files

    6

    Last publish

    Collaborators

    • richienb