rn-currency-formatter
v1.1.1
Published
React Native library that allows users to convert currency symbols to currency ISO currency codes and vic-versa
Downloads
61
Readme
rn-currency-formatter
This is React Native library that helps convert currency symbols into their corresponding ISO currency codes, country names, and amounts, and also works in reverse.
Installation
npm install rn-currency-formatter
or
yarn add rn-currency-formatter
Usage
import { getSymbolInfo, getCodeInfo } from 'rn-currency-formatter';
// ...
const symbolInfo = await getSymbolInfo("$14.6");
const codeInfo = await getCodeInfo("USD 14.6");
// console.log("result : ", symbolInfo or codeInfo)
// output = {
// "symbol": "$",
// "currency_code": "USD",
// "country": "United States Dollar",
// "amount": 14.6
// }
Contributing
See the contributing guide to learn how to contribute to the repository and the development workflow.
License
MIT
Made with create-react-native-library