kapom-report - v0.1.2
    Preparing search index...

    Interface NumericStrategy

    The boundary for all arithmetic in Kapom Report. Never write a + b directly in aggregate/computed/runningTotal — it must go through this strategy. The MVP uses nativeNumeric; migrating to decimal.js later won't need to touch the calling logic.

    interface NumericStrategy {
        add(a: Decimalish, b: Decimalish): Decimalish;
        divide(a: Decimalish, b: Decimalish): Decimalish;
        multiply(a: Decimalish, b: Decimalish): Decimalish;
        subtract(a: Decimalish, b: Decimalish): Decimalish;
        sum(values: readonly Decimalish[]): Decimalish;
        toNumber(value: Decimalish): number;
    }
    Index