next() Packaged Middleware

    @billogram/format
    TypeScript icon, indicating that this package has built-in type declarations

    1.2.4 • Public • Published

    @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

    Keywords

    none

    Install

    npm i @billogram/format

    DownloadsWeekly Downloads

    43

    Version

    1.2.4

    License

    MIT

    Unpacked Size

    65 kB

    Total Files

    71

    Last publish

    Collaborators

    • patrik-at-billo
    • oscarekholm
    • irynaziruikina
    • jmfederico
    • andreagylling
    • ewakosciukiewicz
    • miriamlarsson
    • choddan