NumberCell template
Displays number, this cell allows to customize format number values using Intl.NumberFormat
.
Implementation
Open
NumberCell
implementation on github
Interface declaration
interface NumberCell extends Cell {
type: 'number';
value: number;
format?: Intl.NumberFormat;
nanToZero?: boolean;
hideZero?: boolean;
}
Property name | Type | Property description |
---|---|---|
type | header | Type of cell template |
value | number | Value of cell |
format? | Intl.NumberFormat | Formats value, if undefined formats number according to currect browser locale |
nanToZero? | boolean | If value equals NaN then displays 0 |
hideZero? | boolean | If displayed value equals 0 then value is not rendered |