@bundle-stats/utils 4.1.3 → 4.1.4
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/README.md +26 -0
- package/lib/utils/date.js.map +1 -1
- package/lib-esm/utils/date.js.map +1 -1
- package/package.json +7 -7
- package/src/utils/date.ts +1 -1
package/README.md
CHANGED
|
@@ -34,6 +34,32 @@ console.log(report.insights.webpack.assetsSizeTotal.data.text);
|
|
|
34
34
|
- [Gatsby](https://github.com/relative-ci/bundle-stats/tree/master/packages/gatsby-plugin)
|
|
35
35
|
- [Next](https://github.com/relative-ci/bundle-stats/tree/master/packages/next-plugin)
|
|
36
36
|
|
|
37
|
+
## Packages
|
|
38
|
+
|
|
39
|
+
### [`bundle-stats`](https://github.com/relative-ci/bundle-stats/tree/master/packages/cli)
|
|
40
|
+
|
|
41
|
+
[](https://www.npmjs.com/package/bundle-stats) [](https://www.npmjs.com/package/bundle-stats)
|
|
42
|
+
|
|
43
|
+
CLI to generate bundle stats report.
|
|
44
|
+
|
|
45
|
+
### [`bundle-stats-webpack-plugin`](https://github.com/relative-ci/bundle-stats/tree/master/packages/webpack-plugin)
|
|
46
|
+
|
|
47
|
+
[](https://www.npmjs.com/package/bundle-stats-webpack-plugin) [](https://www.npmjs.com/package/bundle-stats-webpack-plugin)
|
|
48
|
+
|
|
49
|
+
Webpack plugin to generate bundle stats report.
|
|
50
|
+
|
|
51
|
+
### [`gatsby-plugin-bundle-stats`](https://github.com/relative-ci/bundle-stats/tree/master/packages/gatsby-plugin)
|
|
52
|
+
|
|
53
|
+
[](https://www.npmjs.com/package/gatsby-plugin-bundle-stats) [](https://www.npmjs.com/package/gatsby-plugin-bundle-stats)
|
|
54
|
+
|
|
55
|
+
[Gatsby](https://www.gatsbyjs.org) plugin for [bundle-stats](https://github.com/relative-ci/bundle-stats/tree/master/packages/webpack-plugin).
|
|
56
|
+
|
|
57
|
+
### [`next-plugin-bundle-stats`](https://github.com/relative-ci/bundle-stats/tree/master/packages/next-plugin)
|
|
58
|
+
|
|
59
|
+
[](https://www.npmjs.com/package/next-plugin-bundle-stats) [](https://www.npmjs.com/package/next-plugin-bundle-stats)
|
|
60
|
+
|
|
61
|
+
[Next.js](https://nextjs.org) plugin for [bundle-stats](https://github.com/relative-ci/bundle-stats/tree/master/packages/webpack-plugin).
|
|
62
|
+
|
|
37
63
|
|
|
38
64
|
## Related projects
|
|
39
65
|
|
package/lib/utils/date.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"date.js","sourceRoot":"","sources":["../../src/utils/date.ts"],"names":[],"mappings":";;;;;;AAAA,2DAAmC;AAGnC,MAAM,qBAAqB,GAAG,
|
|
1
|
+
{"version":3,"file":"date.js","sourceRoot":"","sources":["../../src/utils/date.ts"],"names":[],"mappings":";;;;;;AAAA,2DAAmC;AAGnC,MAAM,qBAAqB,GAAG,GAA2B,EAAE,CAAC,CAAC,OAAO,MAAM,KAAK,WAAW,IAAI,OAAO,MAAM,CAAC,SAAS,KAAK,WAAW,IAAI,MAAM,CAAC,SAAS,CAAC,SAAS,CAAC,IAAI,IAAI,CAAC;AAE7K,MAAM,iBAAiB,GAAG,CAAC,KAA8B,EAAU,EAAE;IACnE,IAAI,IAAA,gBAAM,EAAC,KAAK,CAAC,EAAE;QACjB,OAAO,KAAK,CAAC,QAAQ,EAAE,CAAC;KACzB;IAED,IAAI,OAAO,KAAK,KAAK,QAAQ,EAAE;QAC7B,OAAO,KAAK,CAAC,QAAQ,EAAE,CAAC;KACzB;IAED,OAAO,KAAK,IAAI,EAAE,CAAC;AACrB,CAAC,CAAC;AAEK,MAAM,cAAc,GAAG,CAC5B,gBAA4C,EAC5C,KAA8B,EACtB,EAAE;IACV,IAAI,IAAI,CAAC;IACT,IAAI,MAAM,GAAG,EAAE,CAAC;IAEhB,IAAI,CAAC,KAAK,EAAE;QACV,OAAO,MAAM,CAAC;KACf;IAED,IAAI,IAAA,gBAAM,EAAC,KAAK,CAAC,EAAE;QACjB,IAAI,GAAG,KAAK,CAAC;KACd;SAAM;QACL,IAAI;YACF,IAAI,GAAG,IAAI,IAAI,CAAC,KAAwB,CAAC,CAAC;SAC3C;QAAC,OAAO,GAAG,EAAE;YAEZ,OAAO,iBAAiB,CAAC,KAAK,CAAC,CAAC;SACjC;KACF;IAED,MAAM,SAAS,GAAG,IAAI,IAAI,CAAC,cAAc,CAAC,qBAAqB,EAAE,EAAE,gBAAgB,CAAC,CAAC;IAErF,IAAI;QACF,MAAM,GAAG,SAAS,CAAC,MAAM,CAAC,IAAI,CAAC,CAAC;KACjC;IAAC,OAAO,GAAG,EAAE;QAEZ,OAAO,iBAAiB,CAAC,KAAK,CAAC,CAAC;KACjC;IAED,OAAO,MAAM,CAAC;AAChB,CAAC,CAAC;AAhCW,QAAA,cAAc,kBAgCzB;AAEK,MAAM,UAAU,GAAG,CAAC,KAA8B,EAAU,EAAE,CACnE,IAAA,sBAAc,EACZ;IACE,GAAG,EAAE,SAAS;IACd,KAAK,EAAE,SAAS;IAChB,IAAI,EAAE,SAAS;CAChB,EACD,KAAK,CACN,CAAC;AARS,QAAA,UAAU,cAQnB;AAEG,MAAM,UAAU,GAAG,CAAC,KAA8B,EAAU,EAAE,CACnE,IAAA,sBAAc,EACZ;IAEE,GAAG,CAAC,OAAO,CAAC,GAAG,CAAC,QAAQ,KAAK,MAAM,IAAI;QACrC,IAAI,EAAE,SAAS;KAChB,CAAC;IACF,MAAM,EAAE,SAAS;IACjB,MAAM,EAAE,SAAS;CAClB,EACD,KAAK,CACN,CAAC;AAXS,QAAA,UAAU,cAWnB"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"date.js","sourceRoot":"","sources":["../../src/utils/date.ts"],"names":[],"mappings":"AAAA,OAAO,MAAM,MAAM,eAAe,CAAC;AAGnC,MAAM,qBAAqB,GAAG,
|
|
1
|
+
{"version":3,"file":"date.js","sourceRoot":"","sources":["../../src/utils/date.ts"],"names":[],"mappings":"AAA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AAC,MAAM,UAAU,GAAG,CAAC,KAA8B,EAAU,EAAE,CACnE,cAAc,CACZ;IACE,GAAG,EAAE,SAAS;IACd,KAAK,EAAE,SAAS;IAChB,IAAI,EAAE,SAAS;CAChB,EACD,KAAK,CACN,CAAC;AAEJ,MAAM,CAAC,MAAM,UAAU,GAAG,CAAC,KAA8B,EAAU,EAAE,CACnE,cAAc,CACZ;IAEE,GAAG,CAAC,OAAO,CAAC,GAAG,CAAC,QAAQ,KAAK,MAAM,IAAI;QACrC,IAAI,EAAE,SAAS;KAChB,CAAC;IACF,MAAM,EAAE,SAAS;IACjB,MAAM,EAAE,SAAS;CAClB,EACD,KAAK,CACN,CAAC"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@bundle-stats/utils",
|
|
3
|
-
"version": "4.1.
|
|
3
|
+
"version": "4.1.4",
|
|
4
4
|
"description": "BundleStats utils",
|
|
5
5
|
"main": "lib/index.js",
|
|
6
6
|
"module": "lib-esm/index.js",
|
|
@@ -35,16 +35,16 @@
|
|
|
35
35
|
},
|
|
36
36
|
"homepage": "https://github.com/relative-ci/bundle-stats/blob/master/packages/utils#readme",
|
|
37
37
|
"dependencies": {
|
|
38
|
-
"@bundle-stats/plugin-webpack-filter": "^4.1.
|
|
39
|
-
"@bundle-stats/plugin-webpack-validate": "^4.1.
|
|
38
|
+
"@bundle-stats/plugin-webpack-filter": "^4.1.4",
|
|
39
|
+
"@bundle-stats/plugin-webpack-validate": "^4.1.4",
|
|
40
40
|
"query-string": "^7.1.0",
|
|
41
41
|
"serialize-query-params": "^2.0.1"
|
|
42
42
|
},
|
|
43
43
|
"devDependencies": {
|
|
44
|
-
"@types/jest": "29.
|
|
45
|
-
"@types/lodash": "4.14.
|
|
44
|
+
"@types/jest": "29.2.3",
|
|
45
|
+
"@types/lodash": "4.14.190",
|
|
46
46
|
"core-js": "3.26.1",
|
|
47
|
-
"jest": "
|
|
47
|
+
"jest": "29.3.1",
|
|
48
48
|
"jest-cli": "29.3.1",
|
|
49
49
|
"jest-date-mock": "1.0.8",
|
|
50
50
|
"lodash": "4.17.21",
|
|
@@ -57,5 +57,5 @@
|
|
|
57
57
|
"core-js": "^3.0.0",
|
|
58
58
|
"lodash": "^4.0.0"
|
|
59
59
|
},
|
|
60
|
-
"gitHead": "
|
|
60
|
+
"gitHead": "47461f88560b103a16ed6d9b587869614a0a4572"
|
|
61
61
|
}
|
package/src/utils/date.ts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import isDate from 'lodash/isDate';
|
|
2
2
|
|
|
3
3
|
// @ts-ignore
|
|
4
|
-
const getNavigatorLanguages = () => (typeof window !== 'undefined' && typeof window.navigator !== 'undefined' && window.navigator.languages) || 'en';
|
|
4
|
+
const getNavigatorLanguages = (): Array<string> | string => (typeof window !== 'undefined' && typeof window.navigator !== 'undefined' && window.navigator.languages) || 'en';
|
|
5
5
|
|
|
6
6
|
const getResultAsString = (value?: Date | string | number): string => {
|
|
7
7
|
if (isDate(value)) {
|