Commit 1bac271 Clément Tessier
committed
1 parent b5b7be1 commit 1bac271 Copy full SHA for 1bac271
File tree 2 files changed +6
-1
lines changed
2 files changed +6
-1
lines changed Original file line number Diff line number Diff line change @@ -8,7 +8,7 @@ const locale = {
8
8
weekdaysMin : 'zo_ma_di_wo_do_vr_za' . split ( '_' ) ,
9
9
months : 'januari_februari_maart_april_mei_juni_juli_augustus_september_oktober_november_december' . split ( '_' ) ,
10
10
monthsShort : 'jan_feb_mrt_apr_mei_jun_jul_aug_sep_okt_nov_dec' . split ( '_' ) ,
11
- ordinal : n => `${ n } ${ n === 1 || n === 8 || n >= 20 ? 'ste' : 'de' } ` ,
11
+ ordinal : n => `[ ${ n } ${ n === 1 || n === 8 || n >= 20 ? 'ste' : 'de' } ] ` ,
12
12
weekStart : 1 ,
13
13
yearStart : 4 ,
14
14
formats : {
Original file line number Diff line number Diff line change @@ -8,6 +8,7 @@ import weekYear from '../../src/plugin/weekYear'
8
8
import timezone from '../../src/plugin/timezone'
9
9
import utc from '../../src/plugin/utc'
10
10
import '../../src/locale/zh-cn'
11
+ import '../../src/locale/nl'
11
12
12
13
dayjs . extend ( utc )
13
14
dayjs . extend ( timezone )
@@ -51,12 +52,16 @@ it('Format Day of Month Do 1 - 31', () => {
51
52
expect ( dayjs ( d ) . format ( 'Do' ) ) . toBe ( moment ( d ) . format ( 'Do' ) )
52
53
d = '2018-05-04 00:00:00.000'
53
54
expect ( dayjs ( d ) . format ( 'Do' ) ) . toBe ( moment ( d ) . format ( 'Do' ) )
55
+ d = '2018-05-08 00:00:00.000'
56
+ expect ( dayjs ( d ) . locale ( 'nl' ) . format ( 'Do' ) ) . toBe ( moment ( d ) . locale ( 'nl' ) . format ( 'Do' ) )
54
57
d = '2018-05-11'
55
58
expect ( dayjs ( d ) . format ( 'Do' ) ) . toBe ( moment ( d ) . format ( 'Do' ) )
56
59
d = '2018-05-12'
57
60
expect ( dayjs ( d ) . format ( 'Do' ) ) . toBe ( moment ( d ) . format ( 'Do' ) )
58
61
d = '2018-05-13'
59
62
expect ( dayjs ( d ) . format ( 'Do' ) ) . toBe ( moment ( d ) . format ( 'Do' ) )
63
+ d = '2018-05-19 00:00:00.000'
64
+ expect ( dayjs ( d ) . locale ( 'nl' ) . format ( 'Do' ) ) . toBe ( moment ( d ) . locale ( 'nl' ) . format ( 'Do' ) )
60
65
d = '2018-05-22'
61
66
expect ( dayjs ( d ) . format ( 'Do' ) ) . toBe ( moment ( d ) . format ( 'Do' ) )
62
67
} )
You can’t perform that action at this time.
0 commit comments