1.5.2 • Published 2 years ago

ody-utils v1.5.2

Weekly downloads
-
License
ISC
Repository
github
Last release
2 years ago

Utility Function

Collection of functions to help with small task that you use frequently.

Thousand Separator

Usage example:

const num = thousandSeparator({ numbers: 100000 });
// num: 100.000

You can also add custom separator (default is '.')

const num = thousandSeparator({ numbers: 100000, separator: ',' });
// num: 100,000

You can also define custom empty placeholder (default is '-')

const num = thousandSeparator({ numbers: '', empty_placeholder: '0' });
// num: '0'

Get Random Number

Usage example:

const randomNumber = getRandomNumber({ min: 1, max: 10 })

The result is inclusive from min value to the max value. For instance if you input min: 1 and max: 10 The result can be ranging from anthing between 1 and 10

1.5.2

2 years ago

1.5.1

2 years ago

1.5.0

2 years ago

1.4.0

2 years ago

1.2.0

2 years ago

1.3.1

2 years ago

1.3.0

2 years ago

1.1.14

2 years ago

1.1.1

3 years ago

1.1.12

2 years ago

1.1.11

2 years ago

1.1.8

2 years ago

1.1.7

2 years ago

1.1.6

2 years ago

1.1.3

2 years ago

1.1.2

3 years ago

1.1.0

3 years ago

1.0.0

3 years ago