@alcorexchange/alcor-swap-sdk
Version:
**npm** ``` npm i @alcorexchange/alcor-swap-sdk ``` **yarn** ``` yarn add @alcorexchange/alcor-swap-sdk ``` ## Usage ### Import:
15 lines (14 loc) • 651 B
TypeScript
import { BigintIsh, Rounding } from "../../internalConstants";
import { Fraction } from "./fraction";
export declare class Percent extends Fraction {
/**
* This boolean prevents a fraction from being interpreted as a Percent
*/
readonly isPercent: true;
add(other: Fraction | BigintIsh): Percent;
subtract(other: Fraction | BigintIsh): Percent;
multiply(other: Fraction | BigintIsh): Percent;
divide(other: Fraction | BigintIsh): Percent;
toSignificant(significantDigits?: number, format?: object, rounding?: Rounding): string;
toFixed(decimalPlaces?: number, format?: object, rounding?: Rounding): string;
}