@daysnap/utils 0.1.18 → 0.1.19
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/docs/classes/Poller.md +151 -0
- package/docs/classes/Storage.md +13 -13
- package/docs/interfaces/EventBusCallback.md +1 -1
- package/docs/interfaces/PollerOptions.md +19 -0
- package/docs/interfaces/StorageManager.md +4 -4
- package/docs/interfaces/Trap.md +5 -5
- package/docs/modules.md +363 -142
- package/es/chunk-AAKGIVZB.js +21 -0
- package/es/chunk-BZ6JSRMY.js +8 -0
- package/es/chunk-EH6HUV2G.js +9 -0
- package/es/chunk-GLJALZRT.js +43 -0
- package/es/chunk-MOZPLBC3.js +8 -0
- package/es/chunk-OOWZEABP.js +8 -0
- package/es/chunk-PXMH56CM.js +8 -0
- package/es/chunk-UDRRKKBB.js +12 -0
- package/es/crToBr.d.ts +6 -0
- package/es/crToBr.js +6 -0
- package/es/crlfToBr.d.ts +11 -0
- package/es/crlfToBr.js +8 -0
- package/es/filterEmptyValue.js +3 -3
- package/es/formatGapDate.d.ts +6 -0
- package/es/formatGapDate.js +6 -0
- package/es/getDateBoundsByMonths.d.ts +1 -1
- package/es/getDaysOfMonth.d.ts +6 -0
- package/es/getDaysOfMonth.js +6 -0
- package/es/getMonthBounds.d.ts +1 -1
- package/es/getWeekBounds.d.ts +7 -0
- package/es/getWeekBounds.js +9 -0
- package/es/index.d.ts +8 -1
- package/es/index.js +124 -94
- package/es/isLeapYear.d.ts +7 -0
- package/es/isLeapYear.js +6 -0
- package/es/lfToBr.d.ts +6 -0
- package/es/lfToBr.js +6 -0
- package/es/poller.d.ts +20 -0
- package/es/poller.js +7 -0
- package/es/stringifyQuery.js +2 -2
- package/lib/chunk-4WWOJSX3.cjs +21 -0
- package/lib/chunk-EUH2FDMT.cjs +8 -0
- package/lib/chunk-TDUDOSU4.cjs +43 -0
- package/lib/chunk-TMCJ3HTA.cjs +12 -0
- package/lib/chunk-UTUKZLEN.cjs +8 -0
- package/lib/chunk-XSCXPGEI.cjs +8 -0
- package/lib/chunk-Z42N5FUV.cjs +9 -0
- package/lib/chunk-ZSDKKWIQ.cjs +8 -0
- package/lib/crToBr.cjs +6 -0
- package/lib/crToBr.d.cts +6 -0
- package/lib/crlfToBr.cjs +8 -0
- package/lib/crlfToBr.d.cts +11 -0
- package/lib/filterEmptyValue.cjs +4 -4
- package/lib/formatGapDate.cjs +6 -0
- package/lib/formatGapDate.d.cts +6 -0
- package/lib/getDateBoundsByMonths.d.cts +1 -1
- package/lib/getDaysOfMonth.cjs +6 -0
- package/lib/getDaysOfMonth.d.cts +6 -0
- package/lib/getMonthBounds.d.cts +1 -1
- package/lib/getWeekBounds.cjs +9 -0
- package/lib/getWeekBounds.d.cts +7 -0
- package/lib/index.cjs +98 -68
- package/lib/index.d.cts +8 -1
- package/lib/isLeapYear.cjs +6 -0
- package/lib/isLeapYear.d.cts +7 -0
- package/lib/lfToBr.cjs +6 -0
- package/lib/lfToBr.d.cts +6 -0
- package/lib/poller.cjs +7 -0
- package/lib/poller.d.cts +20 -0
- package/lib/stringifyQuery.cjs +3 -3
- package/package.json +1 -1
- package/es/chunk-S2FOFDX4.js +0 -8
- package/es/filterCRLF.d.ts +0 -6
- package/es/filterCRLF.js +0 -6
- package/lib/chunk-CXDOHSIF.cjs +0 -8
- package/lib/filterCRLF.cjs +0 -6
- package/lib/filterCRLF.d.cts +0 -6
- package/es/{chunk-NXEL6RMI.js → chunk-SMNIKKYG.js} +6 -6
- package/es/{chunk-VDXSQKQF.js → chunk-WXXFRKUS.js} +3 -3
- package/lib/{chunk-PYFTXKFI.cjs → chunk-4P4EJVBW.cjs} +4 -4
- package/lib/{chunk-73AXP7FD.cjs → chunk-4USHGA4P.cjs} +2 -2
package/docs/modules.md
CHANGED
|
@@ -6,14 +6,20 @@
|
|
|
6
6
|
|
|
7
7
|
### Classes
|
|
8
8
|
|
|
9
|
+
- [Poller](classes/Poller.md)
|
|
9
10
|
- [Storage](classes/Storage.md)
|
|
10
11
|
|
|
11
12
|
### Interfaces
|
|
12
13
|
|
|
13
14
|
- [EventBusCallback](interfaces/EventBusCallback.md)
|
|
15
|
+
- [PollerOptions](interfaces/PollerOptions.md)
|
|
14
16
|
- [StorageManager](interfaces/StorageManager.md)
|
|
15
17
|
- [Trap](interfaces/Trap.md)
|
|
16
18
|
|
|
19
|
+
### Type Aliases
|
|
20
|
+
|
|
21
|
+
- [PollerTask](modules.md#pollertask)
|
|
22
|
+
|
|
17
23
|
### Variables
|
|
18
24
|
|
|
19
25
|
- [eventBus](modules.md#eventbus)
|
|
@@ -37,10 +43,12 @@
|
|
|
37
43
|
- [colorGenByHash](modules.md#colorgenbyhash)
|
|
38
44
|
- [compareVersion](modules.md#compareversion)
|
|
39
45
|
- [compressImage](modules.md#compressimage)
|
|
46
|
+
- [crToBr](modules.md#crtobr)
|
|
40
47
|
- [createFactory](modules.md#createfactory)
|
|
41
48
|
- [createLinearFunction](modules.md#createlinearfunction)
|
|
42
49
|
- [createTrapInstance](modules.md#createtrapinstance)
|
|
43
50
|
- [createWithLoading](modules.md#createwithloading)
|
|
51
|
+
- [crlfToBr](modules.md#crlftobr)
|
|
44
52
|
- [debounce](modules.md#debounce)
|
|
45
53
|
- [downloadFile](modules.md#downloadfile)
|
|
46
54
|
- [each](modules.md#each)
|
|
@@ -59,12 +67,14 @@
|
|
|
59
67
|
- [formatDateStr](modules.md#formatdatestr)
|
|
60
68
|
- [formatDateToZN](modules.md#formatdatetozn)
|
|
61
69
|
- [formatFileSize](modules.md#formatfilesize)
|
|
70
|
+
- [formatGapDate](modules.md#formatgapdate)
|
|
62
71
|
- [formatMessage](modules.md#formatmessage)
|
|
63
72
|
- [formatPathParams](modules.md#formatpathparams)
|
|
64
73
|
- [getBlobByUrl](modules.md#getblobbyurl)
|
|
65
74
|
- [getCache](modules.md#getcache)
|
|
66
75
|
- [getDateBoundsByMonths](modules.md#getdateboundsbymonths)
|
|
67
76
|
- [getDayMillisecond](modules.md#getdaymillisecond)
|
|
77
|
+
- [getDaysOfMonth](modules.md#getdaysofmonth)
|
|
68
78
|
- [getImageInfo](modules.md#getimageinfo)
|
|
69
79
|
- [getLocal](modules.md#getlocal)
|
|
70
80
|
- [getMonthBounds](modules.md#getmonthbounds)
|
|
@@ -74,6 +84,7 @@
|
|
|
74
84
|
- [getRangeDate](modules.md#getrangedate)
|
|
75
85
|
- [getScrollTop](modules.md#getscrolltop)
|
|
76
86
|
- [getVideoInfo](modules.md#getvideoinfo)
|
|
87
|
+
- [getWeekBounds](modules.md#getweekbounds)
|
|
77
88
|
- [getWeekday](modules.md#getweekday)
|
|
78
89
|
- [inBrowser](modules.md#inbrowser)
|
|
79
90
|
- [insertLink](modules.md#insertlink)
|
|
@@ -96,6 +107,7 @@
|
|
|
96
107
|
- [isIdCard](modules.md#isidcard)
|
|
97
108
|
- [isJSONString](modules.md#isjsonstring)
|
|
98
109
|
- [isLan](modules.md#islan)
|
|
110
|
+
- [isLeapYear](modules.md#isleapyear)
|
|
99
111
|
- [isLicenseCode](modules.md#islicensecode)
|
|
100
112
|
- [isMobile](modules.md#ismobile)
|
|
101
113
|
- [isNativeFunction](modules.md#isnativefunction)
|
|
@@ -115,6 +127,7 @@
|
|
|
115
127
|
- [isWeixin](modules.md#isweixin)
|
|
116
128
|
- [isWindow](modules.md#iswindow)
|
|
117
129
|
- [kebabCase](modules.md#kebabcase)
|
|
130
|
+
- [lfToBr](modules.md#lftobr)
|
|
118
131
|
- [listGenerator](modules.md#listgenerator)
|
|
119
132
|
- [makePhoneCall](modules.md#makephonecall)
|
|
120
133
|
- [mousewheel](modules.md#mousewheel)
|
|
@@ -152,6 +165,30 @@
|
|
|
152
165
|
- [withCache](modules.md#withcache)
|
|
153
166
|
- [withPreventConsecutiveClicks](modules.md#withpreventconsecutiveclicks)
|
|
154
167
|
|
|
168
|
+
## Type Aliases
|
|
169
|
+
|
|
170
|
+
### PollerTask
|
|
171
|
+
|
|
172
|
+
Ƭ **PollerTask**: (`poller`: [`Poller`](classes/Poller.md)) => `void` \| `Promise`<`void`\>
|
|
173
|
+
|
|
174
|
+
#### Type declaration
|
|
175
|
+
|
|
176
|
+
▸ (`poller`): `void` \| `Promise`<`void`\>
|
|
177
|
+
|
|
178
|
+
##### Parameters
|
|
179
|
+
|
|
180
|
+
| Name | Type |
|
|
181
|
+
| :------ | :------ |
|
|
182
|
+
| `poller` | [`Poller`](classes/Poller.md) |
|
|
183
|
+
|
|
184
|
+
##### Returns
|
|
185
|
+
|
|
186
|
+
`void` \| `Promise`<`void`\>
|
|
187
|
+
|
|
188
|
+
#### Defined in
|
|
189
|
+
|
|
190
|
+
[poller.ts:7](https://github.com/daysnap/utils/blob/90ba9f7/src/poller.ts#L7)
|
|
191
|
+
|
|
155
192
|
## Variables
|
|
156
193
|
|
|
157
194
|
### eventBus
|
|
@@ -169,7 +206,7 @@
|
|
|
169
206
|
|
|
170
207
|
#### Defined in
|
|
171
208
|
|
|
172
|
-
[eventBus.ts:38](https://github.com/daysnap/utils/blob/
|
|
209
|
+
[eventBus.ts:38](https://github.com/daysnap/utils/blob/90ba9f7/src/eventBus.ts#L38)
|
|
173
210
|
|
|
174
211
|
___
|
|
175
212
|
|
|
@@ -179,7 +216,7 @@ ___
|
|
|
179
216
|
|
|
180
217
|
#### Defined in
|
|
181
218
|
|
|
182
|
-
[trap.ts:15](https://github.com/daysnap/utils/blob/
|
|
219
|
+
[trap.ts:15](https://github.com/daysnap/utils/blob/90ba9f7/src/trap.ts#L15)
|
|
183
220
|
|
|
184
221
|
## Functions
|
|
185
222
|
|
|
@@ -217,7 +254,7 @@ res = { '1': '男', '2': '女' }
|
|
|
217
254
|
|
|
218
255
|
#### Defined in
|
|
219
256
|
|
|
220
|
-
[ato.ts:12](https://github.com/daysnap/utils/blob/
|
|
257
|
+
[ato.ts:12](https://github.com/daysnap/utils/blob/90ba9f7/src/ato.ts#L12)
|
|
221
258
|
|
|
222
259
|
▸ **ato**<`T`, `K`\>(`options`, `labelKey`, `valueKey`): `Record`<`T`[`K`], `any`\>
|
|
223
260
|
|
|
@@ -242,7 +279,7 @@ res = { '1': '男', '2': '女' }
|
|
|
242
279
|
|
|
243
280
|
#### Defined in
|
|
244
281
|
|
|
245
|
-
[ato.ts:16](https://github.com/daysnap/utils/blob/
|
|
282
|
+
[ato.ts:16](https://github.com/daysnap/utils/blob/90ba9f7/src/ato.ts#L16)
|
|
246
283
|
|
|
247
284
|
___
|
|
248
285
|
|
|
@@ -262,7 +299,7 @@ ___
|
|
|
262
299
|
|
|
263
300
|
#### Defined in
|
|
264
301
|
|
|
265
|
-
[decode.ts:41](https://github.com/daysnap/utils/blob/
|
|
302
|
+
[decode.ts:41](https://github.com/daysnap/utils/blob/90ba9f7/src/decode.ts#L41)
|
|
266
303
|
|
|
267
304
|
___
|
|
268
305
|
|
|
@@ -285,7 +322,7 @@ base64 转 blob
|
|
|
285
322
|
|
|
286
323
|
#### Defined in
|
|
287
324
|
|
|
288
|
-
[base64ToBlob.ts:6](https://github.com/daysnap/utils/blob/
|
|
325
|
+
[base64ToBlob.ts:6](https://github.com/daysnap/utils/blob/90ba9f7/src/base64ToBlob.ts#L6)
|
|
289
326
|
|
|
290
327
|
___
|
|
291
328
|
|
|
@@ -308,7 +345,7 @@ blob 转 base64
|
|
|
308
345
|
|
|
309
346
|
#### Defined in
|
|
310
347
|
|
|
311
|
-
[blobToBase64.ts:4](https://github.com/daysnap/utils/blob/
|
|
348
|
+
[blobToBase64.ts:4](https://github.com/daysnap/utils/blob/90ba9f7/src/blobToBase64.ts#L4)
|
|
312
349
|
|
|
313
350
|
___
|
|
314
351
|
|
|
@@ -328,7 +365,7 @@ ___
|
|
|
328
365
|
|
|
329
366
|
#### Defined in
|
|
330
367
|
|
|
331
|
-
[decode.ts:8](https://github.com/daysnap/utils/blob/
|
|
368
|
+
[decode.ts:8](https://github.com/daysnap/utils/blob/90ba9f7/src/decode.ts#L8)
|
|
332
369
|
|
|
333
370
|
___
|
|
334
371
|
|
|
@@ -369,7 +406,7 @@ ___
|
|
|
369
406
|
|
|
370
407
|
#### Defined in
|
|
371
408
|
|
|
372
|
-
[cached.ts:5](https://github.com/daysnap/utils/blob/
|
|
409
|
+
[cached.ts:5](https://github.com/daysnap/utils/blob/90ba9f7/src/cached.ts#L5)
|
|
373
410
|
|
|
374
411
|
___
|
|
375
412
|
|
|
@@ -392,7 +429,7 @@ camelCase('hello-world') => helloWorld
|
|
|
392
429
|
|
|
393
430
|
#### Defined in
|
|
394
431
|
|
|
395
|
-
[camelCase.ts:5](https://github.com/daysnap/utils/blob/
|
|
432
|
+
[camelCase.ts:5](https://github.com/daysnap/utils/blob/90ba9f7/src/camelCase.ts#L5)
|
|
396
433
|
|
|
397
434
|
___
|
|
398
435
|
|
|
@@ -416,7 +453,7 @@ canvas 转 blob 文件
|
|
|
416
453
|
|
|
417
454
|
#### Defined in
|
|
418
455
|
|
|
419
|
-
[canvasToBlob.ts:4](https://github.com/daysnap/utils/blob/
|
|
456
|
+
[canvasToBlob.ts:4](https://github.com/daysnap/utils/blob/90ba9f7/src/canvasToBlob.ts#L4)
|
|
420
457
|
|
|
421
458
|
___
|
|
422
459
|
|
|
@@ -439,7 +476,7 @@ capitalize('hello world') => Hello world
|
|
|
439
476
|
|
|
440
477
|
#### Defined in
|
|
441
478
|
|
|
442
|
-
[capitalize.ts:5](https://github.com/daysnap/utils/blob/
|
|
479
|
+
[capitalize.ts:5](https://github.com/daysnap/utils/blob/90ba9f7/src/capitalize.ts#L5)
|
|
443
480
|
|
|
444
481
|
___
|
|
445
482
|
|
|
@@ -464,7 +501,7 @@ ___
|
|
|
464
501
|
|
|
465
502
|
#### Defined in
|
|
466
503
|
|
|
467
|
-
[chooseMedia.ts:5](https://github.com/daysnap/utils/blob/
|
|
504
|
+
[chooseMedia.ts:5](https://github.com/daysnap/utils/blob/90ba9f7/src/chooseMedia.ts#L5)
|
|
468
505
|
|
|
469
506
|
___
|
|
470
507
|
|
|
@@ -488,7 +525,7 @@ ___
|
|
|
488
525
|
|
|
489
526
|
#### Defined in
|
|
490
527
|
|
|
491
|
-
[clamp.ts:7](https://github.com/daysnap/utils/blob/
|
|
528
|
+
[clamp.ts:7](https://github.com/daysnap/utils/blob/90ba9f7/src/clamp.ts#L7)
|
|
492
529
|
|
|
493
530
|
___
|
|
494
531
|
|
|
@@ -516,7 +553,7 @@ ___
|
|
|
516
553
|
|
|
517
554
|
#### Defined in
|
|
518
555
|
|
|
519
|
-
[clone.ts:8](https://github.com/daysnap/utils/blob/
|
|
556
|
+
[clone.ts:8](https://github.com/daysnap/utils/blob/90ba9f7/src/clone.ts#L8)
|
|
520
557
|
|
|
521
558
|
___
|
|
522
559
|
|
|
@@ -544,7 +581,7 @@ ___
|
|
|
544
581
|
|
|
545
582
|
#### Defined in
|
|
546
583
|
|
|
547
|
-
[cloneSimple.ts:7](https://github.com/daysnap/utils/blob/
|
|
584
|
+
[cloneSimple.ts:7](https://github.com/daysnap/utils/blob/90ba9f7/src/cloneSimple.ts#L7)
|
|
548
585
|
|
|
549
586
|
___
|
|
550
587
|
|
|
@@ -566,7 +603,7 @@ ___
|
|
|
566
603
|
|
|
567
604
|
#### Defined in
|
|
568
605
|
|
|
569
|
-
[createHexColorByHash.ts:4](https://github.com/daysnap/utils/blob/
|
|
606
|
+
[createHexColorByHash.ts:4](https://github.com/daysnap/utils/blob/90ba9f7/src/createHexColorByHash.ts#L4)
|
|
570
607
|
|
|
571
608
|
___
|
|
572
609
|
|
|
@@ -592,7 +629,7 @@ ___
|
|
|
592
629
|
|
|
593
630
|
#### Defined in
|
|
594
631
|
|
|
595
|
-
[compareVersion.ts:9](https://github.com/daysnap/utils/blob/
|
|
632
|
+
[compareVersion.ts:9](https://github.com/daysnap/utils/blob/90ba9f7/src/compareVersion.ts#L9)
|
|
596
633
|
|
|
597
634
|
___
|
|
598
635
|
|
|
@@ -615,7 +652,29 @@ ___
|
|
|
615
652
|
|
|
616
653
|
#### Defined in
|
|
617
654
|
|
|
618
|
-
[compressImage.ts:4](https://github.com/daysnap/utils/blob/
|
|
655
|
+
[compressImage.ts:4](https://github.com/daysnap/utils/blob/90ba9f7/src/compressImage.ts#L4)
|
|
656
|
+
|
|
657
|
+
___
|
|
658
|
+
|
|
659
|
+
### crToBr
|
|
660
|
+
|
|
661
|
+
▸ **crToBr**(`v`): `string`
|
|
662
|
+
|
|
663
|
+
\r to <br/>
|
|
664
|
+
|
|
665
|
+
#### Parameters
|
|
666
|
+
|
|
667
|
+
| Name | Type |
|
|
668
|
+
| :------ | :------ |
|
|
669
|
+
| `v` | `string` |
|
|
670
|
+
|
|
671
|
+
#### Returns
|
|
672
|
+
|
|
673
|
+
`string`
|
|
674
|
+
|
|
675
|
+
#### Defined in
|
|
676
|
+
|
|
677
|
+
[crToBr.ts:4](https://github.com/daysnap/utils/blob/90ba9f7/src/crToBr.ts#L4)
|
|
619
678
|
|
|
620
679
|
___
|
|
621
680
|
|
|
@@ -643,7 +702,7 @@ readonly [(`value`: `T`) => `T`, () => `T`]
|
|
|
643
702
|
|
|
644
703
|
#### Defined in
|
|
645
704
|
|
|
646
|
-
[createFactory.ts:4](https://github.com/daysnap/utils/blob/
|
|
705
|
+
[createFactory.ts:4](https://github.com/daysnap/utils/blob/90ba9f7/src/createFactory.ts#L4)
|
|
647
706
|
|
|
648
707
|
___
|
|
649
708
|
|
|
@@ -681,7 +740,7 @@ ___
|
|
|
681
740
|
|
|
682
741
|
#### Defined in
|
|
683
742
|
|
|
684
|
-
[createLinearFunction.ts:9](https://github.com/daysnap/utils/blob/
|
|
743
|
+
[createLinearFunction.ts:9](https://github.com/daysnap/utils/blob/90ba9f7/src/createLinearFunction.ts#L9)
|
|
685
744
|
|
|
686
745
|
___
|
|
687
746
|
|
|
@@ -713,7 +772,7 @@ ___
|
|
|
713
772
|
|
|
714
773
|
#### Defined in
|
|
715
774
|
|
|
716
|
-
[trap.ts:49](https://github.com/daysnap/utils/blob/
|
|
775
|
+
[trap.ts:49](https://github.com/daysnap/utils/blob/90ba9f7/src/trap.ts#L49)
|
|
717
776
|
|
|
718
777
|
___
|
|
719
778
|
|
|
@@ -776,7 +835,29 @@ fn() 执行的时候就会执行showLoading
|
|
|
776
835
|
|
|
777
836
|
#### Defined in
|
|
778
837
|
|
|
779
|
-
[createWithLoading.ts:11](https://github.com/daysnap/utils/blob/
|
|
838
|
+
[createWithLoading.ts:11](https://github.com/daysnap/utils/blob/90ba9f7/src/createWithLoading.ts#L11)
|
|
839
|
+
|
|
840
|
+
___
|
|
841
|
+
|
|
842
|
+
### crlfToBr
|
|
843
|
+
|
|
844
|
+
▸ **crlfToBr**(`v`): `string`
|
|
845
|
+
|
|
846
|
+
\r \n to <br/>
|
|
847
|
+
|
|
848
|
+
#### Parameters
|
|
849
|
+
|
|
850
|
+
| Name | Type |
|
|
851
|
+
| :------ | :------ |
|
|
852
|
+
| `v` | `string` |
|
|
853
|
+
|
|
854
|
+
#### Returns
|
|
855
|
+
|
|
856
|
+
`string`
|
|
857
|
+
|
|
858
|
+
#### Defined in
|
|
859
|
+
|
|
860
|
+
[crlfToBr.ts:4](https://github.com/daysnap/utils/blob/90ba9f7/src/crlfToBr.ts#L4)
|
|
780
861
|
|
|
781
862
|
___
|
|
782
863
|
|
|
@@ -819,7 +900,7 @@ ___
|
|
|
819
900
|
|
|
820
901
|
#### Defined in
|
|
821
902
|
|
|
822
|
-
[debounce.ts:5](https://github.com/daysnap/utils/blob/
|
|
903
|
+
[debounce.ts:5](https://github.com/daysnap/utils/blob/90ba9f7/src/debounce.ts#L5)
|
|
823
904
|
|
|
824
905
|
___
|
|
825
906
|
|
|
@@ -843,7 +924,7 @@ ___
|
|
|
843
924
|
|
|
844
925
|
#### Defined in
|
|
845
926
|
|
|
846
|
-
[downloadFile.ts:4](https://github.com/daysnap/utils/blob/
|
|
927
|
+
[downloadFile.ts:4](https://github.com/daysnap/utils/blob/90ba9f7/src/downloadFile.ts#L4)
|
|
847
928
|
|
|
848
929
|
___
|
|
849
930
|
|
|
@@ -872,7 +953,7 @@ ___
|
|
|
872
953
|
|
|
873
954
|
#### Defined in
|
|
874
955
|
|
|
875
|
-
[each.ts:4](https://github.com/daysnap/utils/blob/
|
|
956
|
+
[each.ts:4](https://github.com/daysnap/utils/blob/90ba9f7/src/each.ts#L4)
|
|
876
957
|
|
|
877
958
|
▸ **each**<`T`\>(`data`, `callback`): `void`
|
|
878
959
|
|
|
@@ -895,7 +976,7 @@ ___
|
|
|
895
976
|
|
|
896
977
|
#### Defined in
|
|
897
978
|
|
|
898
|
-
[each.ts:8](https://github.com/daysnap/utils/blob/
|
|
979
|
+
[each.ts:8](https://github.com/daysnap/utils/blob/90ba9f7/src/each.ts#L8)
|
|
899
980
|
|
|
900
981
|
___
|
|
901
982
|
|
|
@@ -913,7 +994,7 @@ ___
|
|
|
913
994
|
|
|
914
995
|
#### Defined in
|
|
915
996
|
|
|
916
|
-
[exitFullscreen.ts:6](https://github.com/daysnap/utils/blob/
|
|
997
|
+
[exitFullscreen.ts:6](https://github.com/daysnap/utils/blob/90ba9f7/src/exitFullscreen.ts#L6)
|
|
917
998
|
|
|
918
999
|
___
|
|
919
1000
|
|
|
@@ -942,7 +1023,7 @@ ___
|
|
|
942
1023
|
|
|
943
1024
|
#### Defined in
|
|
944
1025
|
|
|
945
|
-
[storage/factory.ts:11](https://github.com/daysnap/utils/blob/
|
|
1026
|
+
[storage/factory.ts:11](https://github.com/daysnap/utils/blob/90ba9f7/src/storage/factory.ts#L11)
|
|
946
1027
|
|
|
947
1028
|
___
|
|
948
1029
|
|
|
@@ -964,7 +1045,7 @@ ___
|
|
|
964
1045
|
|
|
965
1046
|
#### Defined in
|
|
966
1047
|
|
|
967
|
-
[filterBankCardNo.ts:4](https://github.com/daysnap/utils/blob/
|
|
1048
|
+
[filterBankCardNo.ts:4](https://github.com/daysnap/utils/blob/90ba9f7/src/filterBankCardNo.ts#L4)
|
|
968
1049
|
|
|
969
1050
|
___
|
|
970
1051
|
|
|
@@ -974,6 +1055,14 @@ ___
|
|
|
974
1055
|
|
|
975
1056
|
替换字符串里面的回车换行符
|
|
976
1057
|
|
|
1058
|
+
**`Deprecated`**
|
|
1059
|
+
|
|
1060
|
+
请使用
|
|
1061
|
+
|
|
1062
|
+
**`See`**
|
|
1063
|
+
|
|
1064
|
+
[crlfToBr](modules.md#crlftobr).
|
|
1065
|
+
|
|
977
1066
|
#### Parameters
|
|
978
1067
|
|
|
979
1068
|
| Name | Type |
|
|
@@ -986,7 +1075,7 @@ ___
|
|
|
986
1075
|
|
|
987
1076
|
#### Defined in
|
|
988
1077
|
|
|
989
|
-
[
|
|
1078
|
+
[crlfToBr.ts:12](https://github.com/daysnap/utils/blob/90ba9f7/src/crlfToBr.ts#L12)
|
|
990
1079
|
|
|
991
1080
|
___
|
|
992
1081
|
|
|
@@ -1008,7 +1097,7 @@ ___
|
|
|
1008
1097
|
|
|
1009
1098
|
#### Defined in
|
|
1010
1099
|
|
|
1011
|
-
[filterEmoji.ts:4](https://github.com/daysnap/utils/blob/
|
|
1100
|
+
[filterEmoji.ts:4](https://github.com/daysnap/utils/blob/90ba9f7/src/filterEmoji.ts#L4)
|
|
1012
1101
|
|
|
1013
1102
|
___
|
|
1014
1103
|
|
|
@@ -1031,7 +1120,7 @@ ___
|
|
|
1031
1120
|
|
|
1032
1121
|
#### Defined in
|
|
1033
1122
|
|
|
1034
|
-
[filterEmptyValue.ts:12](https://github.com/daysnap/utils/blob/
|
|
1123
|
+
[filterEmptyValue.ts:12](https://github.com/daysnap/utils/blob/90ba9f7/src/filterEmptyValue.ts#L12)
|
|
1035
1124
|
|
|
1036
1125
|
___
|
|
1037
1126
|
|
|
@@ -1054,7 +1143,7 @@ ___
|
|
|
1054
1143
|
|
|
1055
1144
|
#### Defined in
|
|
1056
1145
|
|
|
1057
|
-
[filterIdCard.ts:5](https://github.com/daysnap/utils/blob/
|
|
1146
|
+
[filterIdCard.ts:5](https://github.com/daysnap/utils/blob/90ba9f7/src/filterIdCard.ts#L5)
|
|
1058
1147
|
|
|
1059
1148
|
___
|
|
1060
1149
|
|
|
@@ -1076,7 +1165,7 @@ ___
|
|
|
1076
1165
|
|
|
1077
1166
|
#### Defined in
|
|
1078
1167
|
|
|
1079
|
-
[filterName.ts:4](https://github.com/daysnap/utils/blob/
|
|
1168
|
+
[filterName.ts:4](https://github.com/daysnap/utils/blob/90ba9f7/src/filterName.ts#L4)
|
|
1080
1169
|
|
|
1081
1170
|
___
|
|
1082
1171
|
|
|
@@ -1101,7 +1190,7 @@ filterPhone('13177778888', ' ') => 131 **** 8888
|
|
|
1101
1190
|
|
|
1102
1191
|
#### Defined in
|
|
1103
1192
|
|
|
1104
|
-
[filterPhone.ts:6](https://github.com/daysnap/utils/blob/
|
|
1193
|
+
[filterPhone.ts:6](https://github.com/daysnap/utils/blob/90ba9f7/src/filterPhone.ts#L6)
|
|
1105
1194
|
|
|
1106
1195
|
___
|
|
1107
1196
|
|
|
@@ -1128,7 +1217,7 @@ str = '131****8888'
|
|
|
1128
1217
|
|
|
1129
1218
|
#### Defined in
|
|
1130
1219
|
|
|
1131
|
-
[filterString.ts:6](https://github.com/daysnap/utils/blob/
|
|
1220
|
+
[filterString.ts:6](https://github.com/daysnap/utils/blob/90ba9f7/src/filterString.ts#L6)
|
|
1132
1221
|
|
|
1133
1222
|
___
|
|
1134
1223
|
|
|
@@ -1151,7 +1240,7 @@ ___
|
|
|
1151
1240
|
|
|
1152
1241
|
#### Defined in
|
|
1153
1242
|
|
|
1154
|
-
[formatAmount.ts:4](https://github.com/daysnap/utils/blob/
|
|
1243
|
+
[formatAmount.ts:4](https://github.com/daysnap/utils/blob/90ba9f7/src/formatAmount.ts#L4)
|
|
1155
1244
|
|
|
1156
1245
|
___
|
|
1157
1246
|
|
|
@@ -1175,7 +1264,7 @@ ___
|
|
|
1175
1264
|
|
|
1176
1265
|
#### Defined in
|
|
1177
1266
|
|
|
1178
|
-
[formatDate.ts:7](https://github.com/daysnap/utils/blob/
|
|
1267
|
+
[formatDate.ts:7](https://github.com/daysnap/utils/blob/90ba9f7/src/formatDate.ts#L7)
|
|
1179
1268
|
|
|
1180
1269
|
___
|
|
1181
1270
|
|
|
@@ -1206,7 +1295,7 @@ fix iOS 日期时间格式如果是 - 就会报错的问题
|
|
|
1206
1295
|
|
|
1207
1296
|
#### Defined in
|
|
1208
1297
|
|
|
1209
|
-
[formatDateStr.ts:6](https://github.com/daysnap/utils/blob/
|
|
1298
|
+
[formatDateStr.ts:6](https://github.com/daysnap/utils/blob/90ba9f7/src/formatDateStr.ts#L6)
|
|
1210
1299
|
|
|
1211
1300
|
___
|
|
1212
1301
|
|
|
@@ -1226,7 +1315,7 @@ ___
|
|
|
1226
1315
|
|
|
1227
1316
|
#### Defined in
|
|
1228
1317
|
|
|
1229
|
-
[formartDateToZN.ts:4](https://github.com/daysnap/utils/blob/
|
|
1318
|
+
[formartDateToZN.ts:4](https://github.com/daysnap/utils/blob/90ba9f7/src/formartDateToZN.ts#L4)
|
|
1230
1319
|
|
|
1231
1320
|
___
|
|
1232
1321
|
|
|
@@ -1249,7 +1338,30 @@ ___
|
|
|
1249
1338
|
|
|
1250
1339
|
#### Defined in
|
|
1251
1340
|
|
|
1252
|
-
[formatFileSize.ts:4](https://github.com/daysnap/utils/blob/
|
|
1341
|
+
[formatFileSize.ts:4](https://github.com/daysnap/utils/blob/90ba9f7/src/formatFileSize.ts#L4)
|
|
1342
|
+
|
|
1343
|
+
___
|
|
1344
|
+
|
|
1345
|
+
### formatGapDate
|
|
1346
|
+
|
|
1347
|
+
▸ **formatGapDate**(`val`, `gap?`): `string`
|
|
1348
|
+
|
|
1349
|
+
yyyyMMdd -> yyyy-MM-dd
|
|
1350
|
+
|
|
1351
|
+
#### Parameters
|
|
1352
|
+
|
|
1353
|
+
| Name | Type | Default value |
|
|
1354
|
+
| :------ | :------ | :------ |
|
|
1355
|
+
| `val` | `string` \| `number` | `undefined` |
|
|
1356
|
+
| `gap` | `string` | `'-'` |
|
|
1357
|
+
|
|
1358
|
+
#### Returns
|
|
1359
|
+
|
|
1360
|
+
`string`
|
|
1361
|
+
|
|
1362
|
+
#### Defined in
|
|
1363
|
+
|
|
1364
|
+
[formatGapDate.ts:4](https://github.com/daysnap/utils/blob/90ba9f7/src/formatGapDate.ts#L4)
|
|
1253
1365
|
|
|
1254
1366
|
___
|
|
1255
1367
|
|
|
@@ -1274,7 +1386,7 @@ formatMessage({ a: '123', b: { ba: '456' } }, ['b.ba']) => '456'
|
|
|
1274
1386
|
|
|
1275
1387
|
#### Defined in
|
|
1276
1388
|
|
|
1277
|
-
[formatMessage.ts:11](https://github.com/daysnap/utils/blob/
|
|
1389
|
+
[formatMessage.ts:11](https://github.com/daysnap/utils/blob/90ba9f7/src/formatMessage.ts#L11)
|
|
1278
1390
|
|
|
1279
1391
|
___
|
|
1280
1392
|
|
|
@@ -1306,7 +1418,7 @@ rest = { xxx: 1 }
|
|
|
1306
1418
|
|
|
1307
1419
|
#### Defined in
|
|
1308
1420
|
|
|
1309
|
-
[formatPathParams.ts:8](https://github.com/daysnap/utils/blob/
|
|
1421
|
+
[formatPathParams.ts:8](https://github.com/daysnap/utils/blob/90ba9f7/src/formatPathParams.ts#L8)
|
|
1310
1422
|
|
|
1311
1423
|
___
|
|
1312
1424
|
|
|
@@ -1328,7 +1440,7 @@ ___
|
|
|
1328
1440
|
|
|
1329
1441
|
#### Defined in
|
|
1330
1442
|
|
|
1331
|
-
[getBlobByUrl.ts:4](https://github.com/daysnap/utils/blob/
|
|
1443
|
+
[getBlobByUrl.ts:4](https://github.com/daysnap/utils/blob/90ba9f7/src/getBlobByUrl.ts#L4)
|
|
1332
1444
|
|
|
1333
1445
|
___
|
|
1334
1446
|
|
|
@@ -1351,7 +1463,7 @@ ___
|
|
|
1351
1463
|
|
|
1352
1464
|
#### Defined in
|
|
1353
1465
|
|
|
1354
|
-
[storage/index.ts:10](https://github.com/daysnap/utils/blob/
|
|
1466
|
+
[storage/index.ts:10](https://github.com/daysnap/utils/blob/90ba9f7/src/storage/index.ts#L10)
|
|
1355
1467
|
|
|
1356
1468
|
___
|
|
1357
1469
|
|
|
@@ -1359,7 +1471,7 @@ ___
|
|
|
1359
1471
|
|
|
1360
1472
|
▸ **getDateBoundsByMonths**(`monthsCount`, `date`): [`Date`, `Date`]
|
|
1361
1473
|
|
|
1362
|
-
|
|
1474
|
+
获取月份开始时间、结束时间
|
|
1363
1475
|
|
|
1364
1476
|
#### Parameters
|
|
1365
1477
|
|
|
@@ -1374,7 +1486,7 @@ ___
|
|
|
1374
1486
|
|
|
1375
1487
|
#### Defined in
|
|
1376
1488
|
|
|
1377
|
-
[getDateBoundsByMonths.ts:8](https://github.com/daysnap/utils/blob/
|
|
1489
|
+
[getDateBoundsByMonths.ts:8](https://github.com/daysnap/utils/blob/90ba9f7/src/getDateBoundsByMonths.ts#L8)
|
|
1378
1490
|
|
|
1379
1491
|
▸ **getDateBoundsByMonths**(`monthsCount`, `date`, `fmt`): [`string`, `string`]
|
|
1380
1492
|
|
|
@@ -1392,7 +1504,7 @@ ___
|
|
|
1392
1504
|
|
|
1393
1505
|
#### Defined in
|
|
1394
1506
|
|
|
1395
|
-
[getDateBoundsByMonths.ts:12](https://github.com/daysnap/utils/blob/
|
|
1507
|
+
[getDateBoundsByMonths.ts:12](https://github.com/daysnap/utils/blob/90ba9f7/src/getDateBoundsByMonths.ts#L12)
|
|
1396
1508
|
|
|
1397
1509
|
___
|
|
1398
1510
|
|
|
@@ -1414,7 +1526,30 @@ ___
|
|
|
1414
1526
|
|
|
1415
1527
|
#### Defined in
|
|
1416
1528
|
|
|
1417
|
-
[getDayMillisecond.ts:4](https://github.com/daysnap/utils/blob/
|
|
1529
|
+
[getDayMillisecond.ts:4](https://github.com/daysnap/utils/blob/90ba9f7/src/getDayMillisecond.ts#L4)
|
|
1530
|
+
|
|
1531
|
+
___
|
|
1532
|
+
|
|
1533
|
+
### getDaysOfMonth
|
|
1534
|
+
|
|
1535
|
+
▸ **getDaysOfMonth**(`year`, `month`): `number`
|
|
1536
|
+
|
|
1537
|
+
获取一个月当中的天数
|
|
1538
|
+
|
|
1539
|
+
#### Parameters
|
|
1540
|
+
|
|
1541
|
+
| Name | Type |
|
|
1542
|
+
| :------ | :------ |
|
|
1543
|
+
| `year` | `number` |
|
|
1544
|
+
| `month` | `number` |
|
|
1545
|
+
|
|
1546
|
+
#### Returns
|
|
1547
|
+
|
|
1548
|
+
`number`
|
|
1549
|
+
|
|
1550
|
+
#### Defined in
|
|
1551
|
+
|
|
1552
|
+
[getDaysOfMonth.ts:4](https://github.com/daysnap/utils/blob/90ba9f7/src/getDaysOfMonth.ts#L4)
|
|
1418
1553
|
|
|
1419
1554
|
___
|
|
1420
1555
|
|
|
@@ -1437,7 +1572,7 @@ ___
|
|
|
1437
1572
|
|
|
1438
1573
|
#### Defined in
|
|
1439
1574
|
|
|
1440
|
-
[getImageInfo.ts:4](https://github.com/daysnap/utils/blob/
|
|
1575
|
+
[getImageInfo.ts:4](https://github.com/daysnap/utils/blob/90ba9f7/src/getImageInfo.ts#L4)
|
|
1441
1576
|
|
|
1442
1577
|
___
|
|
1443
1578
|
|
|
@@ -1460,7 +1595,7 @@ ___
|
|
|
1460
1595
|
|
|
1461
1596
|
#### Defined in
|
|
1462
1597
|
|
|
1463
|
-
[storage/index.ts:10](https://github.com/daysnap/utils/blob/
|
|
1598
|
+
[storage/index.ts:10](https://github.com/daysnap/utils/blob/90ba9f7/src/storage/index.ts#L10)
|
|
1464
1599
|
|
|
1465
1600
|
___
|
|
1466
1601
|
|
|
@@ -1468,7 +1603,7 @@ ___
|
|
|
1468
1603
|
|
|
1469
1604
|
▸ **getMonthBounds**(`value`): [`Date`, `Date`]
|
|
1470
1605
|
|
|
1471
|
-
|
|
1606
|
+
获取月份的开始时间和结束时间
|
|
1472
1607
|
|
|
1473
1608
|
#### Parameters
|
|
1474
1609
|
|
|
@@ -1482,7 +1617,7 @@ ___
|
|
|
1482
1617
|
|
|
1483
1618
|
#### Defined in
|
|
1484
1619
|
|
|
1485
|
-
[getMonthBounds.ts:7](https://github.com/daysnap/utils/blob/
|
|
1620
|
+
[getMonthBounds.ts:7](https://github.com/daysnap/utils/blob/90ba9f7/src/getMonthBounds.ts#L7)
|
|
1486
1621
|
|
|
1487
1622
|
▸ **getMonthBounds**(`value`, `fmt`): [`string`, `string`]
|
|
1488
1623
|
|
|
@@ -1499,7 +1634,7 @@ ___
|
|
|
1499
1634
|
|
|
1500
1635
|
#### Defined in
|
|
1501
1636
|
|
|
1502
|
-
[getMonthBounds.ts:8](https://github.com/daysnap/utils/blob/
|
|
1637
|
+
[getMonthBounds.ts:8](https://github.com/daysnap/utils/blob/90ba9f7/src/getMonthBounds.ts#L8)
|
|
1503
1638
|
|
|
1504
1639
|
___
|
|
1505
1640
|
|
|
@@ -1522,7 +1657,7 @@ ___
|
|
|
1522
1657
|
|
|
1523
1658
|
#### Defined in
|
|
1524
1659
|
|
|
1525
|
-
[getRandom.ts:7](https://github.com/daysnap/utils/blob/
|
|
1660
|
+
[getRandom.ts:7](https://github.com/daysnap/utils/blob/90ba9f7/src/getRandom.ts#L7)
|
|
1526
1661
|
|
|
1527
1662
|
___
|
|
1528
1663
|
|
|
@@ -1538,7 +1673,7 @@ ___
|
|
|
1538
1673
|
|
|
1539
1674
|
#### Defined in
|
|
1540
1675
|
|
|
1541
|
-
[getRandomColor.ts:4](https://github.com/daysnap/utils/blob/
|
|
1676
|
+
[getRandomColor.ts:4](https://github.com/daysnap/utils/blob/90ba9f7/src/getRandomColor.ts#L4)
|
|
1542
1677
|
|
|
1543
1678
|
___
|
|
1544
1679
|
|
|
@@ -1560,7 +1695,7 @@ ___
|
|
|
1560
1695
|
|
|
1561
1696
|
#### Defined in
|
|
1562
1697
|
|
|
1563
|
-
[getRandomNumber.ts:7](https://github.com/daysnap/utils/blob/
|
|
1698
|
+
[getRandomNumber.ts:7](https://github.com/daysnap/utils/blob/90ba9f7/src/getRandomNumber.ts#L7)
|
|
1564
1699
|
|
|
1565
1700
|
___
|
|
1566
1701
|
|
|
@@ -1583,7 +1718,7 @@ ___
|
|
|
1583
1718
|
|
|
1584
1719
|
#### Defined in
|
|
1585
1720
|
|
|
1586
|
-
[getRangeDate.ts:7](https://github.com/daysnap/utils/blob/
|
|
1721
|
+
[getRangeDate.ts:7](https://github.com/daysnap/utils/blob/90ba9f7/src/getRangeDate.ts#L7)
|
|
1587
1722
|
|
|
1588
1723
|
▸ **getRangeDate**(`sv`, `ev`, `fmt`): `string`[]
|
|
1589
1724
|
|
|
@@ -1601,7 +1736,7 @@ ___
|
|
|
1601
1736
|
|
|
1602
1737
|
#### Defined in
|
|
1603
1738
|
|
|
1604
|
-
[getRangeDate.ts:11](https://github.com/daysnap/utils/blob/
|
|
1739
|
+
[getRangeDate.ts:11](https://github.com/daysnap/utils/blob/90ba9f7/src/getRangeDate.ts#L11)
|
|
1605
1740
|
|
|
1606
1741
|
___
|
|
1607
1742
|
|
|
@@ -1617,7 +1752,7 @@ ___
|
|
|
1617
1752
|
|
|
1618
1753
|
#### Defined in
|
|
1619
1754
|
|
|
1620
|
-
[getScrollTop.ts:4](https://github.com/daysnap/utils/blob/
|
|
1755
|
+
[getScrollTop.ts:4](https://github.com/daysnap/utils/blob/90ba9f7/src/getScrollTop.ts#L4)
|
|
1621
1756
|
|
|
1622
1757
|
___
|
|
1623
1758
|
|
|
@@ -1639,7 +1774,48 @@ ___
|
|
|
1639
1774
|
|
|
1640
1775
|
#### Defined in
|
|
1641
1776
|
|
|
1642
|
-
[getVideoInfo.ts:4](https://github.com/daysnap/utils/blob/
|
|
1777
|
+
[getVideoInfo.ts:4](https://github.com/daysnap/utils/blob/90ba9f7/src/getVideoInfo.ts#L4)
|
|
1778
|
+
|
|
1779
|
+
___
|
|
1780
|
+
|
|
1781
|
+
### getWeekBounds
|
|
1782
|
+
|
|
1783
|
+
▸ **getWeekBounds**(`value`, `sundayIsFirstDay`): [`Date`, `Date`]
|
|
1784
|
+
|
|
1785
|
+
获取一周的开始时间和结束时间
|
|
1786
|
+
|
|
1787
|
+
#### Parameters
|
|
1788
|
+
|
|
1789
|
+
| Name | Type |
|
|
1790
|
+
| :------ | :------ |
|
|
1791
|
+
| `value` | `string` \| `number` \| `Date` |
|
|
1792
|
+
| `sundayIsFirstDay` | `boolean` |
|
|
1793
|
+
|
|
1794
|
+
#### Returns
|
|
1795
|
+
|
|
1796
|
+
[`Date`, `Date`]
|
|
1797
|
+
|
|
1798
|
+
#### Defined in
|
|
1799
|
+
|
|
1800
|
+
[getWeekBounds.ts:7](https://github.com/daysnap/utils/blob/90ba9f7/src/getWeekBounds.ts#L7)
|
|
1801
|
+
|
|
1802
|
+
▸ **getWeekBounds**(`value`, `sundayIsFirstDay`, `fmt`): [`string`, `string`]
|
|
1803
|
+
|
|
1804
|
+
#### Parameters
|
|
1805
|
+
|
|
1806
|
+
| Name | Type |
|
|
1807
|
+
| :------ | :------ |
|
|
1808
|
+
| `value` | `string` \| `number` \| `Date` |
|
|
1809
|
+
| `sundayIsFirstDay` | `boolean` |
|
|
1810
|
+
| `fmt` | `string` |
|
|
1811
|
+
|
|
1812
|
+
#### Returns
|
|
1813
|
+
|
|
1814
|
+
[`string`, `string`]
|
|
1815
|
+
|
|
1816
|
+
#### Defined in
|
|
1817
|
+
|
|
1818
|
+
[getWeekBounds.ts:11](https://github.com/daysnap/utils/blob/90ba9f7/src/getWeekBounds.ts#L11)
|
|
1643
1819
|
|
|
1644
1820
|
___
|
|
1645
1821
|
|
|
@@ -1662,7 +1838,7 @@ ___
|
|
|
1662
1838
|
|
|
1663
1839
|
#### Defined in
|
|
1664
1840
|
|
|
1665
|
-
[getWeekday.ts:6](https://github.com/daysnap/utils/blob/
|
|
1841
|
+
[getWeekday.ts:6](https://github.com/daysnap/utils/blob/90ba9f7/src/getWeekday.ts#L6)
|
|
1666
1842
|
|
|
1667
1843
|
___
|
|
1668
1844
|
|
|
@@ -1678,7 +1854,7 @@ ___
|
|
|
1678
1854
|
|
|
1679
1855
|
#### Defined in
|
|
1680
1856
|
|
|
1681
|
-
[inBrowser.ts:4](https://github.com/daysnap/utils/blob/
|
|
1857
|
+
[inBrowser.ts:4](https://github.com/daysnap/utils/blob/90ba9f7/src/inBrowser.ts#L4)
|
|
1682
1858
|
|
|
1683
1859
|
___
|
|
1684
1860
|
|
|
@@ -1700,7 +1876,7 @@ ___
|
|
|
1700
1876
|
|
|
1701
1877
|
#### Defined in
|
|
1702
1878
|
|
|
1703
|
-
[insertLink.ts:4](https://github.com/daysnap/utils/blob/
|
|
1879
|
+
[insertLink.ts:4](https://github.com/daysnap/utils/blob/90ba9f7/src/insertLink.ts#L4)
|
|
1704
1880
|
|
|
1705
1881
|
▸ **insertLink**(`href`, `callback`): `void`
|
|
1706
1882
|
|
|
@@ -1717,7 +1893,7 @@ ___
|
|
|
1717
1893
|
|
|
1718
1894
|
#### Defined in
|
|
1719
1895
|
|
|
1720
|
-
[insertLink.ts:5](https://github.com/daysnap/utils/blob/
|
|
1896
|
+
[insertLink.ts:5](https://github.com/daysnap/utils/blob/90ba9f7/src/insertLink.ts#L5)
|
|
1721
1897
|
|
|
1722
1898
|
___
|
|
1723
1899
|
|
|
@@ -1739,7 +1915,7 @@ ___
|
|
|
1739
1915
|
|
|
1740
1916
|
#### Defined in
|
|
1741
1917
|
|
|
1742
|
-
[insertScript.ts:4](https://github.com/daysnap/utils/blob/
|
|
1918
|
+
[insertScript.ts:4](https://github.com/daysnap/utils/blob/90ba9f7/src/insertScript.ts#L4)
|
|
1743
1919
|
|
|
1744
1920
|
▸ **insertScript**(`src`, `callback`): `void`
|
|
1745
1921
|
|
|
@@ -1756,7 +1932,7 @@ ___
|
|
|
1756
1932
|
|
|
1757
1933
|
#### Defined in
|
|
1758
1934
|
|
|
1759
|
-
[insertScript.ts:5](https://github.com/daysnap/utils/blob/
|
|
1935
|
+
[insertScript.ts:5](https://github.com/daysnap/utils/blob/90ba9f7/src/insertScript.ts#L5)
|
|
1760
1936
|
|
|
1761
1937
|
___
|
|
1762
1938
|
|
|
@@ -1778,7 +1954,7 @@ ___
|
|
|
1778
1954
|
|
|
1779
1955
|
#### Defined in
|
|
1780
1956
|
|
|
1781
|
-
[insertStyle.ts:4](https://github.com/daysnap/utils/blob/
|
|
1957
|
+
[insertStyle.ts:4](https://github.com/daysnap/utils/blob/90ba9f7/src/insertStyle.ts#L4)
|
|
1782
1958
|
|
|
1783
1959
|
___
|
|
1784
1960
|
|
|
@@ -1807,7 +1983,7 @@ isAmount('1.123') => false
|
|
|
1807
1983
|
|
|
1808
1984
|
#### Defined in
|
|
1809
1985
|
|
|
1810
|
-
[isAmount.ts:11](https://github.com/daysnap/utils/blob/
|
|
1986
|
+
[isAmount.ts:11](https://github.com/daysnap/utils/blob/90ba9f7/src/isAmount.ts#L11)
|
|
1811
1987
|
|
|
1812
1988
|
___
|
|
1813
1989
|
|
|
@@ -1823,7 +1999,7 @@ ___
|
|
|
1823
1999
|
|
|
1824
2000
|
#### Defined in
|
|
1825
2001
|
|
|
1826
|
-
[isAndroid.ts:4](https://github.com/daysnap/utils/blob/
|
|
2002
|
+
[isAndroid.ts:4](https://github.com/daysnap/utils/blob/90ba9f7/src/isAndroid.ts#L4)
|
|
1827
2003
|
|
|
1828
2004
|
___
|
|
1829
2005
|
|
|
@@ -1847,7 +2023,7 @@ val is any[]
|
|
|
1847
2023
|
|
|
1848
2024
|
#### Defined in
|
|
1849
2025
|
|
|
1850
|
-
[isArray.ts:6](https://github.com/daysnap/utils/blob/
|
|
2026
|
+
[isArray.ts:6](https://github.com/daysnap/utils/blob/90ba9f7/src/isArray.ts#L6)
|
|
1851
2027
|
|
|
1852
2028
|
___
|
|
1853
2029
|
|
|
@@ -1869,7 +2045,7 @@ val is boolean
|
|
|
1869
2045
|
|
|
1870
2046
|
#### Defined in
|
|
1871
2047
|
|
|
1872
|
-
[isBoolean.ts:5](https://github.com/daysnap/utils/blob/
|
|
2048
|
+
[isBoolean.ts:5](https://github.com/daysnap/utils/blob/90ba9f7/src/isBoolean.ts#L5)
|
|
1873
2049
|
|
|
1874
2050
|
___
|
|
1875
2051
|
|
|
@@ -1891,7 +2067,7 @@ ___
|
|
|
1891
2067
|
|
|
1892
2068
|
#### Defined in
|
|
1893
2069
|
|
|
1894
|
-
[isChinese.ts:4](https://github.com/daysnap/utils/blob/
|
|
2070
|
+
[isChinese.ts:4](https://github.com/daysnap/utils/blob/90ba9f7/src/isChinese.ts#L4)
|
|
1895
2071
|
|
|
1896
2072
|
___
|
|
1897
2073
|
|
|
@@ -1913,7 +2089,7 @@ val is Date
|
|
|
1913
2089
|
|
|
1914
2090
|
#### Defined in
|
|
1915
2091
|
|
|
1916
|
-
[isDate.ts:4](https://github.com/daysnap/utils/blob/
|
|
2092
|
+
[isDate.ts:4](https://github.com/daysnap/utils/blob/90ba9f7/src/isDate.ts#L4)
|
|
1917
2093
|
|
|
1918
2094
|
___
|
|
1919
2095
|
|
|
@@ -1935,7 +2111,7 @@ ___
|
|
|
1935
2111
|
|
|
1936
2112
|
#### Defined in
|
|
1937
2113
|
|
|
1938
|
-
[isEmail.ts:4](https://github.com/daysnap/utils/blob/
|
|
2114
|
+
[isEmail.ts:4](https://github.com/daysnap/utils/blob/90ba9f7/src/isEmail.ts#L4)
|
|
1939
2115
|
|
|
1940
2116
|
___
|
|
1941
2117
|
|
|
@@ -1957,7 +2133,7 @@ ___
|
|
|
1957
2133
|
|
|
1958
2134
|
#### Defined in
|
|
1959
2135
|
|
|
1960
|
-
[isEmpty.ts:6](https://github.com/daysnap/utils/blob/
|
|
2136
|
+
[isEmpty.ts:6](https://github.com/daysnap/utils/blob/90ba9f7/src/isEmpty.ts#L6)
|
|
1961
2137
|
|
|
1962
2138
|
___
|
|
1963
2139
|
|
|
@@ -1979,7 +2155,7 @@ ___
|
|
|
1979
2155
|
|
|
1980
2156
|
#### Defined in
|
|
1981
2157
|
|
|
1982
|
-
[isEmptyArray.ts:6](https://github.com/daysnap/utils/blob/
|
|
2158
|
+
[isEmptyArray.ts:6](https://github.com/daysnap/utils/blob/90ba9f7/src/isEmptyArray.ts#L6)
|
|
1983
2159
|
|
|
1984
2160
|
___
|
|
1985
2161
|
|
|
@@ -2001,7 +2177,7 @@ ___
|
|
|
2001
2177
|
|
|
2002
2178
|
#### Defined in
|
|
2003
2179
|
|
|
2004
|
-
[isEmptyObject.ts:5](https://github.com/daysnap/utils/blob/
|
|
2180
|
+
[isEmptyObject.ts:5](https://github.com/daysnap/utils/blob/90ba9f7/src/isEmptyObject.ts#L5)
|
|
2005
2181
|
|
|
2006
2182
|
___
|
|
2007
2183
|
|
|
@@ -2023,7 +2199,7 @@ val is Error
|
|
|
2023
2199
|
|
|
2024
2200
|
#### Defined in
|
|
2025
2201
|
|
|
2026
|
-
[isError.ts:4](https://github.com/daysnap/utils/blob/
|
|
2202
|
+
[isError.ts:4](https://github.com/daysnap/utils/blob/90ba9f7/src/isError.ts#L4)
|
|
2027
2203
|
|
|
2028
2204
|
___
|
|
2029
2205
|
|
|
@@ -2045,7 +2221,7 @@ val is Function
|
|
|
2045
2221
|
|
|
2046
2222
|
#### Defined in
|
|
2047
2223
|
|
|
2048
|
-
[isFunction.ts:4](https://github.com/daysnap/utils/blob/
|
|
2224
|
+
[isFunction.ts:4](https://github.com/daysnap/utils/blob/90ba9f7/src/isFunction.ts#L4)
|
|
2049
2225
|
|
|
2050
2226
|
___
|
|
2051
2227
|
|
|
@@ -2063,7 +2239,7 @@ ___
|
|
|
2063
2239
|
|
|
2064
2240
|
#### Defined in
|
|
2065
2241
|
|
|
2066
|
-
[isIE.ts:6](https://github.com/daysnap/utils/blob/
|
|
2242
|
+
[isIE.ts:6](https://github.com/daysnap/utils/blob/90ba9f7/src/isIE.ts#L6)
|
|
2067
2243
|
|
|
2068
2244
|
___
|
|
2069
2245
|
|
|
@@ -2079,7 +2255,7 @@ ___
|
|
|
2079
2255
|
|
|
2080
2256
|
#### Defined in
|
|
2081
2257
|
|
|
2082
|
-
[isIOS.ts:4](https://github.com/daysnap/utils/blob/
|
|
2258
|
+
[isIOS.ts:4](https://github.com/daysnap/utils/blob/90ba9f7/src/isIOS.ts#L4)
|
|
2083
2259
|
|
|
2084
2260
|
___
|
|
2085
2261
|
|
|
@@ -2101,7 +2277,7 @@ ___
|
|
|
2101
2277
|
|
|
2102
2278
|
#### Defined in
|
|
2103
2279
|
|
|
2104
|
-
[isIdCard.ts:4](https://github.com/daysnap/utils/blob/
|
|
2280
|
+
[isIdCard.ts:4](https://github.com/daysnap/utils/blob/90ba9f7/src/isIdCard.ts#L4)
|
|
2105
2281
|
|
|
2106
2282
|
___
|
|
2107
2283
|
|
|
@@ -2123,7 +2299,7 @@ ___
|
|
|
2123
2299
|
|
|
2124
2300
|
#### Defined in
|
|
2125
2301
|
|
|
2126
|
-
[isJSONString.ts:7](https://github.com/daysnap/utils/blob/
|
|
2302
|
+
[isJSONString.ts:7](https://github.com/daysnap/utils/blob/90ba9f7/src/isJSONString.ts#L7)
|
|
2127
2303
|
|
|
2128
2304
|
___
|
|
2129
2305
|
|
|
@@ -2145,7 +2321,30 @@ ___
|
|
|
2145
2321
|
|
|
2146
2322
|
#### Defined in
|
|
2147
2323
|
|
|
2148
|
-
[isLan.ts:5](https://github.com/daysnap/utils/blob/
|
|
2324
|
+
[isLan.ts:5](https://github.com/daysnap/utils/blob/90ba9f7/src/isLan.ts#L5)
|
|
2325
|
+
|
|
2326
|
+
___
|
|
2327
|
+
|
|
2328
|
+
### isLeapYear
|
|
2329
|
+
|
|
2330
|
+
▸ **isLeapYear**(`year`): `boolean`
|
|
2331
|
+
|
|
2332
|
+
判断是否是闰年
|
|
2333
|
+
规则:四年一闰,百年不闰,四百年再闰
|
|
2334
|
+
|
|
2335
|
+
#### Parameters
|
|
2336
|
+
|
|
2337
|
+
| Name | Type |
|
|
2338
|
+
| :------ | :------ |
|
|
2339
|
+
| `year` | `number` |
|
|
2340
|
+
|
|
2341
|
+
#### Returns
|
|
2342
|
+
|
|
2343
|
+
`boolean`
|
|
2344
|
+
|
|
2345
|
+
#### Defined in
|
|
2346
|
+
|
|
2347
|
+
[isLeapYear.ts:5](https://github.com/daysnap/utils/blob/90ba9f7/src/isLeapYear.ts#L5)
|
|
2149
2348
|
|
|
2150
2349
|
___
|
|
2151
2350
|
|
|
@@ -2167,7 +2366,7 @@ ___
|
|
|
2167
2366
|
|
|
2168
2367
|
#### Defined in
|
|
2169
2368
|
|
|
2170
|
-
[isLicenseCode.ts:5](https://github.com/daysnap/utils/blob/
|
|
2369
|
+
[isLicenseCode.ts:5](https://github.com/daysnap/utils/blob/90ba9f7/src/isLicenseCode.ts#L5)
|
|
2171
2370
|
|
|
2172
2371
|
___
|
|
2173
2372
|
|
|
@@ -2183,7 +2382,7 @@ ___
|
|
|
2183
2382
|
|
|
2184
2383
|
#### Defined in
|
|
2185
2384
|
|
|
2186
|
-
[isMobile.ts:4](https://github.com/daysnap/utils/blob/
|
|
2385
|
+
[isMobile.ts:4](https://github.com/daysnap/utils/blob/90ba9f7/src/isMobile.ts#L4)
|
|
2187
2386
|
|
|
2188
2387
|
___
|
|
2189
2388
|
|
|
@@ -2206,7 +2405,7 @@ ___
|
|
|
2206
2405
|
|
|
2207
2406
|
#### Defined in
|
|
2208
2407
|
|
|
2209
|
-
[isNativeFunction.ts:7](https://github.com/daysnap/utils/blob/
|
|
2408
|
+
[isNativeFunction.ts:7](https://github.com/daysnap/utils/blob/90ba9f7/src/isNativeFunction.ts#L7)
|
|
2210
2409
|
|
|
2211
2410
|
___
|
|
2212
2411
|
|
|
@@ -2228,7 +2427,7 @@ val is null
|
|
|
2228
2427
|
|
|
2229
2428
|
#### Defined in
|
|
2230
2429
|
|
|
2231
|
-
[isNull.ts:4](https://github.com/daysnap/utils/blob/
|
|
2430
|
+
[isNull.ts:4](https://github.com/daysnap/utils/blob/90ba9f7/src/isNull.ts#L4)
|
|
2232
2431
|
|
|
2233
2432
|
___
|
|
2234
2433
|
|
|
@@ -2250,7 +2449,7 @@ val is number
|
|
|
2250
2449
|
|
|
2251
2450
|
#### Defined in
|
|
2252
2451
|
|
|
2253
|
-
[isNumber.ts:5](https://github.com/daysnap/utils/blob/
|
|
2452
|
+
[isNumber.ts:5](https://github.com/daysnap/utils/blob/90ba9f7/src/isNumber.ts#L5)
|
|
2254
2453
|
|
|
2255
2454
|
___
|
|
2256
2455
|
|
|
@@ -2272,7 +2471,7 @@ val is Record<string, any\>
|
|
|
2272
2471
|
|
|
2273
2472
|
#### Defined in
|
|
2274
2473
|
|
|
2275
|
-
[isObject.ts:4](https://github.com/daysnap/utils/blob/
|
|
2474
|
+
[isObject.ts:4](https://github.com/daysnap/utils/blob/90ba9f7/src/isObject.ts#L4)
|
|
2276
2475
|
|
|
2277
2476
|
___
|
|
2278
2477
|
|
|
@@ -2294,7 +2493,7 @@ ___
|
|
|
2294
2493
|
|
|
2295
2494
|
#### Defined in
|
|
2296
2495
|
|
|
2297
|
-
[isPhone.ts:4](https://github.com/daysnap/utils/blob/
|
|
2496
|
+
[isPhone.ts:4](https://github.com/daysnap/utils/blob/90ba9f7/src/isPhone.ts#L4)
|
|
2298
2497
|
|
|
2299
2498
|
___
|
|
2300
2499
|
|
|
@@ -2322,7 +2521,7 @@ val is Promise<T\>
|
|
|
2322
2521
|
|
|
2323
2522
|
#### Defined in
|
|
2324
2523
|
|
|
2325
|
-
[isPromise.ts:4](https://github.com/daysnap/utils/blob/
|
|
2524
|
+
[isPromise.ts:4](https://github.com/daysnap/utils/blob/90ba9f7/src/isPromise.ts#L4)
|
|
2326
2525
|
|
|
2327
2526
|
___
|
|
2328
2527
|
|
|
@@ -2344,7 +2543,7 @@ val is RegExp
|
|
|
2344
2543
|
|
|
2345
2544
|
#### Defined in
|
|
2346
2545
|
|
|
2347
|
-
[isRegExp.ts:4](https://github.com/daysnap/utils/blob/
|
|
2546
|
+
[isRegExp.ts:4](https://github.com/daysnap/utils/blob/90ba9f7/src/isRegExp.ts#L4)
|
|
2348
2547
|
|
|
2349
2548
|
___
|
|
2350
2549
|
|
|
@@ -2366,7 +2565,7 @@ val is string
|
|
|
2366
2565
|
|
|
2367
2566
|
#### Defined in
|
|
2368
2567
|
|
|
2369
|
-
[isString.ts:4](https://github.com/daysnap/utils/blob/
|
|
2568
|
+
[isString.ts:4](https://github.com/daysnap/utils/blob/90ba9f7/src/isString.ts#L4)
|
|
2370
2569
|
|
|
2371
2570
|
___
|
|
2372
2571
|
|
|
@@ -2395,7 +2594,7 @@ val is T
|
|
|
2395
2594
|
|
|
2396
2595
|
#### Defined in
|
|
2397
2596
|
|
|
2398
|
-
[isType.ts:4](https://github.com/daysnap/utils/blob/
|
|
2597
|
+
[isType.ts:4](https://github.com/daysnap/utils/blob/90ba9f7/src/isType.ts#L4)
|
|
2399
2598
|
|
|
2400
2599
|
___
|
|
2401
2600
|
|
|
@@ -2417,7 +2616,7 @@ val is undefined
|
|
|
2417
2616
|
|
|
2418
2617
|
#### Defined in
|
|
2419
2618
|
|
|
2420
|
-
[isUndefined.ts:4](https://github.com/daysnap/utils/blob/
|
|
2619
|
+
[isUndefined.ts:4](https://github.com/daysnap/utils/blob/90ba9f7/src/isUndefined.ts#L4)
|
|
2421
2620
|
|
|
2422
2621
|
___
|
|
2423
2622
|
|
|
@@ -2439,7 +2638,7 @@ ___
|
|
|
2439
2638
|
|
|
2440
2639
|
#### Defined in
|
|
2441
2640
|
|
|
2442
|
-
[isURL.ts:4](https://github.com/daysnap/utils/blob/
|
|
2641
|
+
[isURL.ts:4](https://github.com/daysnap/utils/blob/90ba9f7/src/isURL.ts#L4)
|
|
2443
2642
|
|
|
2444
2643
|
___
|
|
2445
2644
|
|
|
@@ -2461,7 +2660,7 @@ ___
|
|
|
2461
2660
|
|
|
2462
2661
|
#### Defined in
|
|
2463
2662
|
|
|
2464
|
-
[isValidDate.ts:6](https://github.com/daysnap/utils/blob/
|
|
2663
|
+
[isValidDate.ts:6](https://github.com/daysnap/utils/blob/90ba9f7/src/isValidDate.ts#L6)
|
|
2465
2664
|
|
|
2466
2665
|
___
|
|
2467
2666
|
|
|
@@ -2477,7 +2676,7 @@ ___
|
|
|
2477
2676
|
|
|
2478
2677
|
#### Defined in
|
|
2479
2678
|
|
|
2480
|
-
[isWeChat.ts:4](https://github.com/daysnap/utils/blob/
|
|
2679
|
+
[isWeChat.ts:4](https://github.com/daysnap/utils/blob/90ba9f7/src/isWeChat.ts#L4)
|
|
2481
2680
|
|
|
2482
2681
|
___
|
|
2483
2682
|
|
|
@@ -2494,7 +2693,7 @@ https://developers.weixin.qq.com/miniprogram/dev/component/web-view.html
|
|
|
2494
2693
|
|
|
2495
2694
|
#### Defined in
|
|
2496
2695
|
|
|
2497
|
-
[isWeChatMiniProgram.ts:5](https://github.com/daysnap/utils/blob/
|
|
2696
|
+
[isWeChatMiniProgram.ts:5](https://github.com/daysnap/utils/blob/90ba9f7/src/isWeChatMiniProgram.ts#L5)
|
|
2498
2697
|
|
|
2499
2698
|
___
|
|
2500
2699
|
|
|
@@ -2518,7 +2717,7 @@ ___
|
|
|
2518
2717
|
|
|
2519
2718
|
#### Defined in
|
|
2520
2719
|
|
|
2521
|
-
[isWeChat.ts:12](https://github.com/daysnap/utils/blob/
|
|
2720
|
+
[isWeChat.ts:12](https://github.com/daysnap/utils/blob/90ba9f7/src/isWeChat.ts#L12)
|
|
2522
2721
|
|
|
2523
2722
|
___
|
|
2524
2723
|
|
|
@@ -2540,7 +2739,7 @@ val is Window
|
|
|
2540
2739
|
|
|
2541
2740
|
#### Defined in
|
|
2542
2741
|
|
|
2543
|
-
[isWindow.ts:5](https://github.com/daysnap/utils/blob/
|
|
2742
|
+
[isWindow.ts:5](https://github.com/daysnap/utils/blob/90ba9f7/src/isWindow.ts#L5)
|
|
2544
2743
|
|
|
2545
2744
|
___
|
|
2546
2745
|
|
|
@@ -2563,7 +2762,29 @@ kebabCase('helloWorld') => hello-world
|
|
|
2563
2762
|
|
|
2564
2763
|
#### Defined in
|
|
2565
2764
|
|
|
2566
|
-
[kebabCase.ts:5](https://github.com/daysnap/utils/blob/
|
|
2765
|
+
[kebabCase.ts:5](https://github.com/daysnap/utils/blob/90ba9f7/src/kebabCase.ts#L5)
|
|
2766
|
+
|
|
2767
|
+
___
|
|
2768
|
+
|
|
2769
|
+
### lfToBr
|
|
2770
|
+
|
|
2771
|
+
▸ **lfToBr**(`v`): `string`
|
|
2772
|
+
|
|
2773
|
+
\n to <br/>
|
|
2774
|
+
|
|
2775
|
+
#### Parameters
|
|
2776
|
+
|
|
2777
|
+
| Name | Type |
|
|
2778
|
+
| :------ | :------ |
|
|
2779
|
+
| `v` | `string` |
|
|
2780
|
+
|
|
2781
|
+
#### Returns
|
|
2782
|
+
|
|
2783
|
+
`string`
|
|
2784
|
+
|
|
2785
|
+
#### Defined in
|
|
2786
|
+
|
|
2787
|
+
[lfToBr.ts:4](https://github.com/daysnap/utils/blob/90ba9f7/src/lfToBr.ts#L4)
|
|
2567
2788
|
|
|
2568
2789
|
___
|
|
2569
2790
|
|
|
@@ -2585,7 +2806,7 @@ list 生成器,快速生成数据
|
|
|
2585
2806
|
|
|
2586
2807
|
#### Defined in
|
|
2587
2808
|
|
|
2588
|
-
[listGenerator.ts:5](https://github.com/daysnap/utils/blob/
|
|
2809
|
+
[listGenerator.ts:5](https://github.com/daysnap/utils/blob/90ba9f7/src/listGenerator.ts#L5)
|
|
2589
2810
|
|
|
2590
2811
|
▸ **listGenerator**<`T`\>(`length`, `fn`): `T`[]
|
|
2591
2812
|
|
|
@@ -2608,7 +2829,7 @@ list 生成器,快速生成数据
|
|
|
2608
2829
|
|
|
2609
2830
|
#### Defined in
|
|
2610
2831
|
|
|
2611
|
-
[listGenerator.ts:6](https://github.com/daysnap/utils/blob/
|
|
2832
|
+
[listGenerator.ts:6](https://github.com/daysnap/utils/blob/90ba9f7/src/listGenerator.ts#L6)
|
|
2612
2833
|
|
|
2613
2834
|
___
|
|
2614
2835
|
|
|
@@ -2628,7 +2849,7 @@ ___
|
|
|
2628
2849
|
|
|
2629
2850
|
#### Defined in
|
|
2630
2851
|
|
|
2631
|
-
[makePhoneCall.ts:1](https://github.com/daysnap/utils/blob/
|
|
2852
|
+
[makePhoneCall.ts:1](https://github.com/daysnap/utils/blob/90ba9f7/src/makePhoneCall.ts#L1)
|
|
2632
2853
|
|
|
2633
2854
|
___
|
|
2634
2855
|
|
|
@@ -2653,7 +2874,7 @@ ___
|
|
|
2653
2874
|
|
|
2654
2875
|
#### Defined in
|
|
2655
2876
|
|
|
2656
|
-
[mousewheel.ts:22](https://github.com/daysnap/utils/blob/
|
|
2877
|
+
[mousewheel.ts:22](https://github.com/daysnap/utils/blob/90ba9f7/src/mousewheel.ts#L22)
|
|
2657
2878
|
|
|
2658
2879
|
___
|
|
2659
2880
|
|
|
@@ -2669,7 +2890,7 @@ ___
|
|
|
2669
2890
|
|
|
2670
2891
|
#### Defined in
|
|
2671
2892
|
|
|
2672
|
-
[nf.ts:4](https://github.com/daysnap/utils/blob/
|
|
2893
|
+
[nf.ts:4](https://github.com/daysnap/utils/blob/90ba9f7/src/nf.ts#L4)
|
|
2673
2894
|
|
|
2674
2895
|
___
|
|
2675
2896
|
|
|
@@ -2693,7 +2914,7 @@ fix iOS 日期时间格式如果类似是 2020-12-12 12:12:12 就会报错的问
|
|
|
2693
2914
|
|
|
2694
2915
|
#### Defined in
|
|
2695
2916
|
|
|
2696
|
-
[normalizeDate.ts:8](https://github.com/daysnap/utils/blob/
|
|
2917
|
+
[normalizeDate.ts:8](https://github.com/daysnap/utils/blob/90ba9f7/src/normalizeDate.ts#L8)
|
|
2697
2918
|
|
|
2698
2919
|
___
|
|
2699
2920
|
|
|
@@ -2715,7 +2936,7 @@ ___
|
|
|
2715
2936
|
|
|
2716
2937
|
#### Defined in
|
|
2717
2938
|
|
|
2718
|
-
[normalizePath.ts:4](https://github.com/daysnap/utils/blob/
|
|
2939
|
+
[normalizePath.ts:4](https://github.com/daysnap/utils/blob/90ba9f7/src/normalizePath.ts#L4)
|
|
2719
2940
|
|
|
2720
2941
|
___
|
|
2721
2942
|
|
|
@@ -2745,7 +2966,7 @@ ___
|
|
|
2745
2966
|
|
|
2746
2967
|
#### Defined in
|
|
2747
2968
|
|
|
2748
|
-
[omit.ts:4](https://github.com/daysnap/utils/blob/
|
|
2969
|
+
[omit.ts:4](https://github.com/daysnap/utils/blob/90ba9f7/src/omit.ts#L4)
|
|
2749
2970
|
|
|
2750
2971
|
___
|
|
2751
2972
|
|
|
@@ -2769,7 +2990,7 @@ ___
|
|
|
2769
2990
|
|
|
2770
2991
|
#### Defined in
|
|
2771
2992
|
|
|
2772
|
-
[padding.ts:7](https://github.com/daysnap/utils/blob/
|
|
2993
|
+
[padding.ts:7](https://github.com/daysnap/utils/blob/90ba9f7/src/padding.ts#L7)
|
|
2773
2994
|
|
|
2774
2995
|
___
|
|
2775
2996
|
|
|
@@ -2795,7 +3016,7 @@ ___
|
|
|
2795
3016
|
|
|
2796
3017
|
#### Defined in
|
|
2797
3018
|
|
|
2798
|
-
[parseDate.ts:5](https://github.com/daysnap/utils/blob/
|
|
3019
|
+
[parseDate.ts:5](https://github.com/daysnap/utils/blob/90ba9f7/src/parseDate.ts#L5)
|
|
2799
3020
|
|
|
2800
3021
|
___
|
|
2801
3022
|
|
|
@@ -2818,7 +3039,7 @@ ___
|
|
|
2818
3039
|
|
|
2819
3040
|
#### Defined in
|
|
2820
3041
|
|
|
2821
|
-
[parseError.ts:8](https://github.com/daysnap/utils/blob/
|
|
3042
|
+
[parseError.ts:8](https://github.com/daysnap/utils/blob/90ba9f7/src/parseError.ts#L8)
|
|
2822
3043
|
|
|
2823
3044
|
___
|
|
2824
3045
|
|
|
@@ -2848,7 +3069,7 @@ parseObject('a.b.c', 1) => { a: { b: { c: 1 } } }
|
|
|
2848
3069
|
|
|
2849
3070
|
#### Defined in
|
|
2850
3071
|
|
|
2851
|
-
[parseObject.ts:5](https://github.com/daysnap/utils/blob/
|
|
3072
|
+
[parseObject.ts:5](https://github.com/daysnap/utils/blob/90ba9f7/src/parseObject.ts#L5)
|
|
2852
3073
|
|
|
2853
3074
|
___
|
|
2854
3075
|
|
|
@@ -2877,7 +3098,7 @@ ___
|
|
|
2877
3098
|
|
|
2878
3099
|
#### Defined in
|
|
2879
3100
|
|
|
2880
|
-
[parsePath.ts:6](https://github.com/daysnap/utils/blob/
|
|
3101
|
+
[parsePath.ts:6](https://github.com/daysnap/utils/blob/90ba9f7/src/parsePath.ts#L6)
|
|
2881
3102
|
|
|
2882
3103
|
___
|
|
2883
3104
|
|
|
@@ -2900,7 +3121,7 @@ ___
|
|
|
2900
3121
|
|
|
2901
3122
|
#### Defined in
|
|
2902
3123
|
|
|
2903
|
-
[parseQuery.ts:8](https://github.com/daysnap/utils/blob/
|
|
3124
|
+
[parseQuery.ts:8](https://github.com/daysnap/utils/blob/90ba9f7/src/parseQuery.ts#L8)
|
|
2904
3125
|
|
|
2905
3126
|
___
|
|
2906
3127
|
|
|
@@ -2930,7 +3151,7 @@ ___
|
|
|
2930
3151
|
|
|
2931
3152
|
#### Defined in
|
|
2932
3153
|
|
|
2933
|
-
[parseQueryString.ts:6](https://github.com/daysnap/utils/blob/
|
|
3154
|
+
[parseQueryString.ts:6](https://github.com/daysnap/utils/blob/90ba9f7/src/parseQueryString.ts#L6)
|
|
2934
3155
|
|
|
2935
3156
|
___
|
|
2936
3157
|
|
|
@@ -2953,7 +3174,7 @@ pascalCase('hello-world') => HelloWorld
|
|
|
2953
3174
|
|
|
2954
3175
|
#### Defined in
|
|
2955
3176
|
|
|
2956
|
-
[pascalCase.ts:8](https://github.com/daysnap/utils/blob/
|
|
3177
|
+
[pascalCase.ts:8](https://github.com/daysnap/utils/blob/90ba9f7/src/pascalCase.ts#L8)
|
|
2957
3178
|
|
|
2958
3179
|
___
|
|
2959
3180
|
|
|
@@ -2983,7 +3204,7 @@ ___
|
|
|
2983
3204
|
|
|
2984
3205
|
#### Defined in
|
|
2985
3206
|
|
|
2986
|
-
[pick.ts:4](https://github.com/daysnap/utils/blob/
|
|
3207
|
+
[pick.ts:4](https://github.com/daysnap/utils/blob/90ba9f7/src/pick.ts#L4)
|
|
2987
3208
|
|
|
2988
3209
|
___
|
|
2989
3210
|
|
|
@@ -3006,7 +3227,7 @@ ___
|
|
|
3006
3227
|
|
|
3007
3228
|
#### Defined in
|
|
3008
3229
|
|
|
3009
|
-
[replaceCrlf.ts:4](https://github.com/daysnap/utils/blob/
|
|
3230
|
+
[replaceCrlf.ts:4](https://github.com/daysnap/utils/blob/90ba9f7/src/replaceCrlf.ts#L4)
|
|
3010
3231
|
|
|
3011
3232
|
___
|
|
3012
3233
|
|
|
@@ -3030,7 +3251,7 @@ ___
|
|
|
3030
3251
|
|
|
3031
3252
|
#### Defined in
|
|
3032
3253
|
|
|
3033
|
-
[requestFullScreen.ts:6](https://github.com/daysnap/utils/blob/
|
|
3254
|
+
[requestFullScreen.ts:6](https://github.com/daysnap/utils/blob/90ba9f7/src/requestFullScreen.ts#L6)
|
|
3034
3255
|
|
|
3035
3256
|
___
|
|
3036
3257
|
|
|
@@ -3056,7 +3277,7 @@ reserve(0, '--') => 0
|
|
|
3056
3277
|
|
|
3057
3278
|
#### Defined in
|
|
3058
3279
|
|
|
3059
|
-
[reserve.ts:8](https://github.com/daysnap/utils/blob/
|
|
3280
|
+
[reserve.ts:8](https://github.com/daysnap/utils/blob/90ba9f7/src/reserve.ts#L8)
|
|
3060
3281
|
|
|
3061
3282
|
___
|
|
3062
3283
|
|
|
@@ -3080,7 +3301,7 @@ ___
|
|
|
3080
3301
|
|
|
3081
3302
|
#### Defined in
|
|
3082
3303
|
|
|
3083
|
-
[rgbToHex.ts:4](https://github.com/daysnap/utils/blob/
|
|
3304
|
+
[rgbToHex.ts:4](https://github.com/daysnap/utils/blob/90ba9f7/src/rgbToHex.ts#L4)
|
|
3084
3305
|
|
|
3085
3306
|
___
|
|
3086
3307
|
|
|
@@ -3103,7 +3324,7 @@ ___
|
|
|
3103
3324
|
|
|
3104
3325
|
#### Defined in
|
|
3105
3326
|
|
|
3106
|
-
[round.ts:6](https://github.com/daysnap/utils/blob/
|
|
3327
|
+
[round.ts:6](https://github.com/daysnap/utils/blob/90ba9f7/src/round.ts#L6)
|
|
3107
3328
|
|
|
3108
3329
|
___
|
|
3109
3330
|
|
|
@@ -3119,7 +3340,7 @@ ___
|
|
|
3119
3340
|
|
|
3120
3341
|
#### Defined in
|
|
3121
3342
|
|
|
3122
|
-
[scrollToTop.ts:4](https://github.com/daysnap/utils/blob/
|
|
3343
|
+
[scrollToTop.ts:4](https://github.com/daysnap/utils/blob/90ba9f7/src/scrollToTop.ts#L4)
|
|
3123
3344
|
|
|
3124
3345
|
___
|
|
3125
3346
|
|
|
@@ -3141,7 +3362,7 @@ ___
|
|
|
3141
3362
|
|
|
3142
3363
|
#### Defined in
|
|
3143
3364
|
|
|
3144
|
-
[setScrollTop.ts:4](https://github.com/daysnap/utils/blob/
|
|
3365
|
+
[setScrollTop.ts:4](https://github.com/daysnap/utils/blob/90ba9f7/src/setScrollTop.ts#L4)
|
|
3145
3366
|
|
|
3146
3367
|
___
|
|
3147
3368
|
|
|
@@ -3164,7 +3385,7 @@ ___
|
|
|
3164
3385
|
|
|
3165
3386
|
#### Defined in
|
|
3166
3387
|
|
|
3167
|
-
[sleep.ts:6](https://github.com/daysnap/utils/blob/
|
|
3388
|
+
[sleep.ts:6](https://github.com/daysnap/utils/blob/90ba9f7/src/sleep.ts#L6)
|
|
3168
3389
|
|
|
3169
3390
|
___
|
|
3170
3391
|
|
|
@@ -3193,7 +3414,7 @@ ___
|
|
|
3193
3414
|
|
|
3194
3415
|
#### Defined in
|
|
3195
3416
|
|
|
3196
|
-
[splitArray.ts:4](https://github.com/daysnap/utils/blob/
|
|
3417
|
+
[splitArray.ts:4](https://github.com/daysnap/utils/blob/90ba9f7/src/splitArray.ts#L4)
|
|
3197
3418
|
|
|
3198
3419
|
___
|
|
3199
3420
|
|
|
@@ -3216,7 +3437,7 @@ ___
|
|
|
3216
3437
|
|
|
3217
3438
|
#### Defined in
|
|
3218
3439
|
|
|
3219
|
-
[stringTrim.ts:6](https://github.com/daysnap/utils/blob/
|
|
3440
|
+
[stringTrim.ts:6](https://github.com/daysnap/utils/blob/90ba9f7/src/stringTrim.ts#L6)
|
|
3220
3441
|
|
|
3221
3442
|
___
|
|
3222
3443
|
|
|
@@ -3238,7 +3459,7 @@ ___
|
|
|
3238
3459
|
|
|
3239
3460
|
#### Defined in
|
|
3240
3461
|
|
|
3241
|
-
[stringifyQuery.ts:7](https://github.com/daysnap/utils/blob/
|
|
3462
|
+
[stringifyQuery.ts:7](https://github.com/daysnap/utils/blob/90ba9f7/src/stringifyQuery.ts#L7)
|
|
3242
3463
|
|
|
3243
3464
|
___
|
|
3244
3465
|
|
|
@@ -3262,7 +3483,7 @@ ___
|
|
|
3262
3483
|
|
|
3263
3484
|
#### Defined in
|
|
3264
3485
|
|
|
3265
|
-
[stringifyQueryString.ts:6](https://github.com/daysnap/utils/blob/
|
|
3486
|
+
[stringifyQueryString.ts:6](https://github.com/daysnap/utils/blob/90ba9f7/src/stringifyQueryString.ts#L6)
|
|
3266
3487
|
|
|
3267
3488
|
___
|
|
3268
3489
|
|
|
@@ -3306,7 +3527,7 @@ ___
|
|
|
3306
3527
|
|
|
3307
3528
|
#### Defined in
|
|
3308
3529
|
|
|
3309
|
-
[throttle.ts:48](https://github.com/daysnap/utils/blob/
|
|
3530
|
+
[throttle.ts:48](https://github.com/daysnap/utils/blob/90ba9f7/src/throttle.ts#L48)
|
|
3310
3531
|
|
|
3311
3532
|
___
|
|
3312
3533
|
|
|
@@ -3349,7 +3570,7 @@ ___
|
|
|
3349
3570
|
|
|
3350
3571
|
#### Defined in
|
|
3351
3572
|
|
|
3352
|
-
[throttle.ts:5](https://github.com/daysnap/utils/blob/
|
|
3573
|
+
[throttle.ts:5](https://github.com/daysnap/utils/blob/90ba9f7/src/throttle.ts#L5)
|
|
3353
3574
|
|
|
3354
3575
|
___
|
|
3355
3576
|
|
|
@@ -3392,7 +3613,7 @@ ___
|
|
|
3392
3613
|
|
|
3393
3614
|
#### Defined in
|
|
3394
3615
|
|
|
3395
|
-
[throttle.ts:25](https://github.com/daysnap/utils/blob/
|
|
3616
|
+
[throttle.ts:25](https://github.com/daysnap/utils/blob/90ba9f7/src/throttle.ts#L25)
|
|
3396
3617
|
|
|
3397
3618
|
___
|
|
3398
3619
|
|
|
@@ -3414,7 +3635,7 @@ ___
|
|
|
3414
3635
|
|
|
3415
3636
|
#### Defined in
|
|
3416
3637
|
|
|
3417
|
-
[toCDB.ts:4](https://github.com/daysnap/utils/blob/
|
|
3638
|
+
[toCDB.ts:4](https://github.com/daysnap/utils/blob/90ba9f7/src/toCDB.ts#L4)
|
|
3418
3639
|
|
|
3419
3640
|
___
|
|
3420
3641
|
|
|
@@ -3436,7 +3657,7 @@ ___
|
|
|
3436
3657
|
|
|
3437
3658
|
#### Defined in
|
|
3438
3659
|
|
|
3439
|
-
[toDBC.ts:4](https://github.com/daysnap/utils/blob/
|
|
3660
|
+
[toDBC.ts:4](https://github.com/daysnap/utils/blob/90ba9f7/src/toDBC.ts#L4)
|
|
3440
3661
|
|
|
3441
3662
|
___
|
|
3442
3663
|
|
|
@@ -3460,7 +3681,7 @@ ___
|
|
|
3460
3681
|
|
|
3461
3682
|
#### Defined in
|
|
3462
3683
|
|
|
3463
|
-
[typeOf.ts:6](https://github.com/daysnap/utils/blob/
|
|
3684
|
+
[typeOf.ts:6](https://github.com/daysnap/utils/blob/90ba9f7/src/typeOf.ts#L6)
|
|
3464
3685
|
|
|
3465
3686
|
___
|
|
3466
3687
|
|
|
@@ -3488,7 +3709,7 @@ ___
|
|
|
3488
3709
|
|
|
3489
3710
|
#### Defined in
|
|
3490
3711
|
|
|
3491
|
-
[withCache.ts:4](https://github.com/daysnap/utils/blob/
|
|
3712
|
+
[withCache.ts:4](https://github.com/daysnap/utils/blob/90ba9f7/src/withCache.ts#L4)
|
|
3492
3713
|
|
|
3493
3714
|
___
|
|
3494
3715
|
|
|
@@ -3517,4 +3738,4 @@ ___
|
|
|
3517
3738
|
|
|
3518
3739
|
#### Defined in
|
|
3519
3740
|
|
|
3520
|
-
[withPreventConsecutiveClicks.ts:4](https://github.com/daysnap/utils/blob/
|
|
3741
|
+
[withPreventConsecutiveClicks.ts:4](https://github.com/daysnap/utils/blob/90ba9f7/src/withPreventConsecutiveClicks.ts#L4)
|