numbertowords-solidity

1.1.1 • Public • Published

Number To Word Solidity Library

This library was made by refractoring the following number-to-words repository: https://github.com/marlun78/number-to-words

Contains some util methods for converting numbers into words.

Install

npm install numbertowords-solidity

Usage

API

toWords(number)

Converts an integer into words.

import "numbertowords-solidity/contracts/NumberToWords.sol";

NumberToWords.toWords(13); // => “thirteen”

NumberToWords.toWords(56); // => “fifty-six”

// Large numbers:
NumberToWords.toWords(9007199254740992); // => “nine quadrillion, seven trillion, one hundred ninety-nine billion, two hundred fifty-four million, seven hundred forty thousand, nine hundred ninety-two”

Acknowledgments

Thank You

Feel free to contact me at

LinkedIn

Readme

Keywords

none

Package Sidebar

Install

npm i numbertowords-solidity

Weekly Downloads

0

Version

1.1.1

License

MIT

Unpacked Size

4.09 MB

Total Files

21

Last publish

Collaborators

  • yassin_rahim93