UNPKG

@melonproject/token-math

Version:

A small helper library to do precision safe calculations

11 lines (10 loc) 436 B
"use strict"; var __importDefault = (this && this.__importDefault) || function (mod) { return (mod && mod.__esModule) ? mod : { "default": mod }; }; Object.defineProperty(exports, "__esModule", { value: true }); const BigInteger_1 = __importDefault(require("./BigInteger")); const toBI = value => value.hasOwnProperty("value") && Array.isArray(value.value) ? value : new BigInteger_1.default(value); exports.default = toBI;