Skip to content

Commit f8ec92e

Browse files
author
Dipak Sarkar
committed
updated docs with new config
1 parent 084b296 commit f8ec92e

File tree

2 files changed

+5
-5
lines changed

2 files changed

+5
-5
lines changed

docs/guide/config.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ The following options can be passed as an object literal to the NumberFormat fun
2626
- Type: `number`
2727
- Default: `2`
2828
- Required: `false`
29-
## null_value
29+
## nullValue
3030

3131
- Type: `number`
3232
- Default: `0`

tests/unit/number-format.custom.spec.js

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -5,15 +5,15 @@ describe('should not throw error on empty config', () => {
55
prefix: '$',
66
separator: '.',
77
decimal: ',',
8-
null_value: 0,
8+
nullValue: 0,
99
})).not.toThrow()
1010
})
1111
describe('when the value is invalid with custom config', () => {
1212
const numberFormat = new NumberFormat({
1313
prefix: '$',
1414
separator: '.',
1515
decimal: ',',
16-
null_value: 0,
16+
nullValue: 0,
1717
})
1818
it('should return as follows', () => {
1919
expect(numberFormat.format('')).toEqual('')
@@ -44,7 +44,7 @@ describe('format when options are custom', () => {
4444
prefix: '$',
4545
separator: '.',
4646
decimal: ',',
47-
null_value: '',
47+
nullValue: '',
4848
})
4949
it('format string value', () => {
5050
expect(numberFormat.format('0')).toEqual('$0')
@@ -88,7 +88,7 @@ describe('unformat when options are default', () => {
8888
prefix: '$',
8989
separator: '.',
9090
decimal: ',',
91-
null_value: '',
91+
nullValue: '',
9292
})
9393
it('unformat string value', () => {
9494
expect(numberFormat.clean(true).unformat('0')).toEqual('0')

0 commit comments

Comments
 (0)