A React component for formatting currency values using a customizable pattern. Version 1.1.0 supports React 16.x. It provides a simple declarative API with optional props for locale, pattern, decimal, and group separators. Unlike other currency formatters, it uses a pattern string for flexible formatting. However, it is not actively maintained (last update years ago) and has known issues with locale support and TypeScript definitions.
npm install react-currency-formatterNo compatibility data collected yet for this library.
Verified import paths — ran on the pinned version, not inferred.
Shows basic usage of the Currency component with a quantity, currency code, and locale.
Use pattern, decimal, group props for consistent formatting or test with target locales.
Create a .d.ts file: declare module 'react-currency-formatter' { const Currency: any; export default Currency; }Consider using Intl.NumberFormat directly or a maintained alternative like react-number-format.
Avoid pattern when locale is set; or test thoroughly.
Use require('react-currency-formatter').default or switch to import syntax.Upgrade to a patched version or fork and filter unknown props.
npm install react-currency-formatter --save