@billogram/format
v1.2.4
Published
> Functions for formatting data
Downloads
20
Keywords
Readme
@billogram/format
Functions for formatting data
Install
yarn add @billogram/format
Usage
import {
formatAddress,
formatBankgiro,
formatDatetime,
formatIban,
formatMaybeDatetime,
formatMoney,
formatNumber,
formatOrganizationNumber,
formatRelativeDatetime,
formatThousandDelimiter,
formatValidOrNotValid,
formatYesNo,
formatZipcode,
} from '@billogram/format';
formatAddress
formatAddress({
att: '',
careof: '',
city: '',
country: '',
name: '',
street: '',
zipcode: '',
});
formatBankgiro
formatBankgiro(value);
formatDatetime
formatDatetime(timestamp);
formatIban
formatIban(iban);
formatMaybeDatetime
formatMaybeDatetime(timestamp);
formatMoney
formatMoney(value, currency);
formatNumber
formatNumber(value);
formatOrganizationNumber
formatOrganizationNumber(orgNo);
formatRelativeDatetime
formatRelativeDatetime(timestamp);
formatThousandDelimiter
formatThousandDelimiter(value);
formatValidOrNotValid
formatValidOrNotValid(value);
formatYesNo
formatYesNo(value);
formatZipcode
formatZipcode(value, country);
Note
This library is being published with our use cases in mind and is not necessarily meant to be consumed by the broader public. We probably won't take your feature requests unless they align with our own needs.
License
MIT