Document Number Formatter

JSON →
library 1.0.33 ·javascript
verified Jun 4, 2026

A lightweight TypeScript library for generating formatted document numbers such as bill numbers, invoice numbers, or custom identifiers. The current stable version is 1.0.33, and it is actively maintained with periodic updates. Key differentiators include support for date-based formatting (year, month, day), sequential value formatting with zero-padding, and fiscal year logic. It is designed for Node.js and browser environments and integrates easily with frameworks like Vue, React, and Angular. The library provides three main functions: formatDocumentNumber, fdnForDate, and formatDate. It is ESM and CJS compatible, ships TypeScript definitions, and has zero external dependencies.