A precision-first numeric input library for any web application. Zero dependencies, TypeScript-first, framework agnostic.
| Package | Version | Description |
|---|---|---|
numora | Core - vanilla JS/TypeScript | |
numora-react | React component wrapper |
# Core (vanilla JS/TypeScript)
npm install numora
# React
npm install numora-reactimport{NumoraInput}from'numora';constinput=newNumoraInput(document.querySelector('#amount'),{decimalMaxLength: 2,thousandSeparator: ',',onChange: (value)=>console.log(value),});import{NumoraInput}from'numora-react';<NumoraInputmaxDecimals={2}thousandSeparator=","onChange={(e)=>console.log(e.target.value)}/>- Sanitization - filters invalid characters, mobile keyboard artifacts, and non-numeric input
- Formatting - thousand separators with Thousand/Lakh/Wan grouping styles, format on blur or change
- Decimals - configurable min/max decimal places, custom decimal separator
- Compact Notation - expands "1k" → "1000", "1.5m" → "1500000" on paste/setValue
- Scientific Notation - automatically expands "1.5e-7" → "0.00000015"
- Leading Zeros - configurable leading zero behavior
Full documentation, live demo, and examples at numora.xyz.
MIT - Kacper Szarkiewicz