How to use the esp-js.Guard.isTruthy function in esp-js

To help you get started, we’ve selected a few esp-js examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github esp / esp-js / packages / esp-js-ui / src / core / decimal.ts View on Github external
constructor(unscaledValue: number, scale = 0) {
        Guard.isTruthy(Utils.isInt(unscaledValue), 'unscaledValue must be an int');
        Guard.isTruthy(Utils.isInt(scale), 'scale must be an int');
        this._unscaledValue = unscaledValue;
        this._scale = scale;
    }
github esp / esp-js / packages / esp-js-ui / src / core / decimal.ts View on Github external
constructor(unscaledValue: number, scale = 0) {
        Guard.isTruthy(Utils.isInt(unscaledValue), 'unscaledValue must be an int');
        Guard.isTruthy(Utils.isInt(scale), 'scale must be an int');
        this._unscaledValue = unscaledValue;
        this._scale = scale;
    }