mazey 2.0.0 → 2.1.0
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/LICENSE +1 -1
- package/README.md +17 -4
- package/index.js +3 -0
- package/lib/index.cjs.js +1 -4786
- package/lib/index.d.ts +81 -81
- package/lib/index.d.ts.map +1 -1
- package/lib/index.esm.js +1 -4739
- package/lib/mazey.min.js +1 -0
- package/package.json +13 -15
- package/src/index.ts +112 -96
- package/tsconfig.json +2 -1
- package/typing.d.ts +3 -3
- package/lib/example.d.ts +0 -2
- package/lib/example.d.ts.map +0 -1
package/LICENSE
CHANGED
package/README.md
CHANGED
|
@@ -137,8 +137,8 @@ Transfer CamelCase to Underscore.
|
|
|
137
137
|
```
|
|
138
138
|
import { camelCase2Underscore } from 'mazey';
|
|
139
139
|
|
|
140
|
-
camelCase2Underscore('ABC'); //
|
|
141
|
-
camelCase2Underscore('aBC'); //
|
|
140
|
+
camelCase2Underscore('ABC'); // a_b_c
|
|
141
|
+
camelCase2Underscore('aBC'); // a_b_c
|
|
142
142
|
```
|
|
143
143
|
|
|
144
144
|
#### Trim
|
|
@@ -398,12 +398,25 @@ calLongestCommonSubsequence('fish', 'finish'); // 4
|
|
|
398
398
|
### Browser Information
|
|
399
399
|
|
|
400
400
|
```
|
|
401
|
-
import {
|
|
401
|
+
import { getBrowserInfo } from 'mazey';
|
|
402
402
|
|
|
403
|
-
|
|
403
|
+
getBrowserInfo(); // {"engine":"webkit","engineVs":"537.36","platform":"desktop","supporter":"chrome","supporterVs":"85.0.4183.121","system":"windows","systemVs":"10"}
|
|
404
404
|
// Shell and shell version { shell: 'wechat', shellVs: '20' } shell: wechat qq uc 360 2345 sougou liebao maxthon
|
|
405
405
|
```
|
|
406
406
|
|
|
407
|
+
| Index | Field | Description |
|
|
408
|
+
| --- | --- | --- |
|
|
409
|
+
| * System | system | android, ios, windows, macos, linux |
|
|
410
|
+
| * System version | systemVs | windows: 2000, xp, 2003, vista, 7, 8, 8.1, 10<br />macos: ... |
|
|
411
|
+
| * Platform | platform | desktop, mobile |
|
|
412
|
+
| * Engine | engine | webkit, gecko, presto, trident |
|
|
413
|
+
| * Engine version | engineVs | - |
|
|
414
|
+
| * Supporter | supporter | edge, opera, chrome, safari, firefox, iexplore |
|
|
415
|
+
| * Supporter version | supporterVs | - |
|
|
416
|
+
| Shell | shell | wechat, qq_browser, qq_app, uc, 360, 2345, sougou, liebao, maxthon, bilibili |
|
|
417
|
+
| Shell version | shellVs | - |
|
|
418
|
+
| Apple device type | appleType | iphone, ipad, ipod, iwatch |
|
|
419
|
+
|
|
407
420
|
### Web Performance
|
|
408
421
|
|
|
409
422
|
Get page load time(PerformanceTiming).
|
package/index.js
CHANGED