React Intl Currency Input screenshot

React Intl Currency Input

Author Avatar Theme by Thiagozanetti
Updated: 4 Apr 2023
196 Stars

React component for i18n currency input using Intl API.

Categories

Overview

The react-intl-currency-input is a React component designed for internationalization currency input using the Intl API. It allows users to input currency values in different formats and currencies with ease.

Features

  • defaultValue: Sets the initial value of the input field.
  • currency: Specifies the currency code to be used.
  • config: USD related configuration compliant with react-intl intlShape.
  • autoFocus: Enables auto-focus when the component is displayed.
  • autoSelect: Enables auto-select when the component is displayed.
  • autoReset: Resets the component’s internal state when it loses focus.
  • Events: Allows for event handling such as onChange, onFocus, onBlur, and onKeyPress.
  • max: Specifies the maximum value for the input field.

Installation

To install the react-intl-currency-input component in your React project, you can use npm:

npm install react-intl-currency-input

Summary

The react-intl-currency-input React component is a useful tool for developers looking to incorporate international currency input functionality into their web applications. With features like setting default values, specifying currency codes, and event handling capabilities, it provides a convenient solution for handling currency inputs with internationalization support.