Branded numeric type for negative integers. Represents integers strictly less than zero.
const isNegativeInt = (x: number): x is NegativeInt => Number.isInteger(x) && x < 0;const offset = (value: NegativeInt) => ({ offset: value });const depth = (level: NegativeInt) => ({ belowGround: -level }); Copy
const isNegativeInt = (x: number): x is NegativeInt => Number.isInteger(x) && x < 0;const offset = (value: NegativeInt) => ({ offset: value });const depth = (level: NegativeInt) => ({ belowGround: -level });
Branded numeric type for negative integers. Represents integers strictly less than zero.