bundle-stats 4.2.0-beta.1 → 4.2.0-beta.2

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.
@@ -1,234 +1,4 @@
1
1
  {
2
- "createdAt": "2022-12-29T18:54:32.551Z",
3
- "version": "4.2.0-beta.1",
4
- "runs": [
5
- {
6
- "webpack": {
7
- "chunks": [
8
- {
9
- "id": "0",
10
- "name": "login~signup"
11
- },
12
- {
13
- "id": "1",
14
- "name": "login"
15
- },
16
- {
17
- "id": "2",
18
- "name": "main"
19
- },
20
- {
21
- "id": "3",
22
- "name": "project"
23
- },
24
- {
25
- "id": "4",
26
- "name": "signup"
27
- },
28
- {
29
- "id": "5",
30
- "name": "vendors"
31
- }
32
- ],
33
- "builtAt": "",
34
- "hash": "5cd0eb52be263c21059c"
35
- },
36
- "internalBuildNumber": 2
37
- },
38
- {
39
- "webpack": {
40
- "chunks": [
41
- {
42
- "id": "0",
43
- "name": "main"
44
- },
45
- {
46
- "id": "1",
47
- "name": "vendors"
48
- }
49
- ],
50
- "builtAt": "",
51
- "hash": "f3e1d64f9494a7ab429e"
52
- },
53
- "internalBuildNumber": 1
54
- }
55
- ],
56
- "summary": {
57
- "webpack": [
58
- {
59
- "label": "Bundle Size",
60
- "value": 2097917,
61
- "displayValue": "2MiB",
62
- "delta": -67252,
63
- "deltaPercentage": -3.10608548,
64
- "displayDelta": "-65.68KiB",
65
- "displayDeltaPercentage": "-3.11%",
66
- "deltaType": "LOW_POSITIVE"
67
- },
68
- {
69
- "label": "Initial JS",
70
- "value": 1265645,
71
- "displayValue": "1.21MiB",
72
- "delta": -773358,
73
- "deltaPercentage": -37.92824238,
74
- "displayDelta": "-755.23KiB",
75
- "displayDeltaPercentage": "-37.93%",
76
- "deltaType": "POSITIVE"
77
- },
78
- {
79
- "label": "Initial CSS",
80
- "value": 48866,
81
- "displayValue": "47.72KiB",
82
- "delta": -16917,
83
- "deltaPercentage": -25.71637049,
84
- "displayDelta": "-16.52KiB",
85
- "displayDeltaPercentage": "-25.72%",
86
- "deltaType": "POSITIVE"
87
- },
88
- {
89
- "label": "Cache Invalidation",
90
- "value": 97.21,
91
- "displayValue": "97.21%",
92
- "delta": 97.21,
93
- "deltaPercentage": 100,
94
- "displayDelta": "+97.21%",
95
- "displayDeltaPercentage": "+100%",
96
- "deltaType": "HIGH_NEGATIVE"
97
- },
98
- {
99
- "label": "Modules",
100
- "value": 1074,
101
- "displayValue": "1074",
102
- "delta": -72,
103
- "deltaPercentage": -6.28272251,
104
- "displayDelta": "-72",
105
- "displayDeltaPercentage": "-6.28%",
106
- "deltaType": "POSITIVE"
107
- },
108
- {
109
- "label": "Duplicate Modules",
110
- "value": 6,
111
- "displayValue": "6",
112
- "delta": 4,
113
- "deltaPercentage": 200,
114
- "displayDelta": "+4",
115
- "displayDeltaPercentage": "+200%",
116
- "deltaType": "HIGH_NEGATIVE"
117
- },
118
- {
119
- "label": "Duplicate Code",
120
- "value": 1.14,
121
- "displayValue": "1.14%",
122
- "delta": 0.9799999999999999,
123
- "deltaPercentage": 612.5,
124
- "displayDelta": "+0.98%",
125
- "displayDeltaPercentage": "+612.5%",
126
- "deltaType": "HIGH_NEGATIVE"
127
- },
128
- {
129
- "label": "Chunks",
130
- "value": 12,
131
- "displayValue": "12",
132
- "delta": 8,
133
- "deltaPercentage": 200,
134
- "displayDelta": "+8",
135
- "displayDeltaPercentage": "+200%",
136
- "deltaType": "HIGH_NEGATIVE"
137
- },
138
- {
139
- "label": "Assets",
140
- "value": 26,
141
- "displayValue": "26",
142
- "delta": 8,
143
- "deltaPercentage": 44.44444444,
144
- "displayDelta": "+8",
145
- "displayDeltaPercentage": "+44.44%",
146
- "deltaType": "NEGATIVE"
147
- },
148
- {
149
- "label": "Packages",
150
- "value": 146,
151
- "displayValue": "146",
152
- "delta": 3,
153
- "deltaPercentage": 2.0979021,
154
- "displayDelta": "+3",
155
- "displayDeltaPercentage": "+2.1%",
156
- "deltaType": "LOW_NEGATIVE"
157
- },
158
- {
159
- "label": "Duplicate Packages",
160
- "value": 13,
161
- "displayValue": "13",
162
- "delta": 2,
163
- "deltaPercentage": 18.18181818,
164
- "displayDelta": "+2",
165
- "displayDeltaPercentage": "+18.18%",
166
- "deltaType": "NEGATIVE"
167
- }
168
- ]
169
- },
170
- "insights": {
171
- "webpack": {
172
- "assetsSizeTotal": {
173
- "type": "INFO",
174
- "data": {
175
- "text": "Bundle Size — 2MiB (-3.11%).",
176
- "md": "*Bundle Size* — *2MiB* (*-3.11%*).",
177
- "info": {
178
- "value": 2097917,
179
- "displayValue": "2MiB",
180
- "delta": -67252,
181
- "deltaPercentage": -3.10608548,
182
- "displayDelta": "-65.68KiB",
183
- "displayDeltaPercentage": "-3.11%",
184
- "deltaType": "LOW_POSITIVE"
185
- }
186
- }
187
- },
188
- "duplicatePackages": {
189
- "type": "WARNING",
190
- "data": {
191
- "tslib": [
192
- "@firebase/app:tslib",
193
- "@firebase/util:tslib",
194
- "@firebase/component:tslib",
195
- "tslib"
196
- ],
197
- "lodash.throttle": [
198
- "lodash.throttle~1",
199
- "@bundle-stats/ui:lodash.throttle",
200
- "lodash.throttle"
201
- ],
202
- "object-keys": [
203
- "document.contains:object-keys",
204
- "object.values:object-keys"
205
- ],
206
- "react-is": [
207
- "recharts:react-is",
208
- "orbit-ui-react:react-is",
209
- "react-is"
210
- ],
211
- "@babel/runtime": [
212
- "orbit-ui-react:@babel/runtime",
213
- "@babel/runtime",
214
- "mini-create-react-context:@babel/runtime"
215
- ],
216
- "hoist-non-react-statics": [
217
- "react-router:hoist-non-react-statics",
218
- "hoist-non-react-statics"
219
- ],
220
- "define-properties": [
221
- "object.values:define-properties",
222
- "document.contains:define-properties"
223
- ],
224
- "has": [
225
- "object.values:has",
226
- "has"
227
- ]
228
- }
229
- }
230
- }
231
- },
232
2
  "stats": [
233
3
  {
234
4
  "key": "webpack.totalSizeByTypeALL",
@@ -39254,5 +39024,280 @@
39254
39024
  "label": "d3-path",
39255
39025
  "changed": false
39256
39026
  }
39257
- ]
39027
+ ],
39028
+ "createdAt": "2023-02-01T21:23:57.885Z",
39029
+ "version": "4.2.0-beta.2",
39030
+ "runs": [
39031
+ {
39032
+ "webpack": {
39033
+ "chunks": [
39034
+ {
39035
+ "id": "0",
39036
+ "name": "login~signup"
39037
+ },
39038
+ {
39039
+ "id": "1",
39040
+ "name": "login"
39041
+ },
39042
+ {
39043
+ "id": "2",
39044
+ "name": "main"
39045
+ },
39046
+ {
39047
+ "id": "3",
39048
+ "name": "project"
39049
+ },
39050
+ {
39051
+ "id": "4",
39052
+ "name": "signup"
39053
+ },
39054
+ {
39055
+ "id": "5",
39056
+ "name": "vendors"
39057
+ }
39058
+ ],
39059
+ "builtAt": "",
39060
+ "hash": "5cd0eb52be263c21059c"
39061
+ },
39062
+ "internalBuildNumber": 2
39063
+ },
39064
+ {
39065
+ "webpack": {
39066
+ "chunks": [
39067
+ {
39068
+ "id": "0",
39069
+ "name": "main"
39070
+ },
39071
+ {
39072
+ "id": "1",
39073
+ "name": "vendors"
39074
+ }
39075
+ ],
39076
+ "builtAt": "",
39077
+ "hash": "f3e1d64f9494a7ab429e"
39078
+ },
39079
+ "internalBuildNumber": 1
39080
+ }
39081
+ ],
39082
+ "summary": {
39083
+ "webpack": [
39084
+ {
39085
+ "value": 2097917,
39086
+ "displayValue": "2MiB",
39087
+ "delta": -67252,
39088
+ "deltaPercentage": -3.10608548,
39089
+ "displayDelta": "-65.68KiB",
39090
+ "displayDeltaPercentage": "-3.11%",
39091
+ "deltaType": "LOW_POSITIVE",
39092
+ "label": "Bundle Size"
39093
+ },
39094
+ {
39095
+ "value": 1265645,
39096
+ "displayValue": "1.21MiB",
39097
+ "delta": -773358,
39098
+ "deltaPercentage": -37.92824238,
39099
+ "displayDelta": "-755.23KiB",
39100
+ "displayDeltaPercentage": "-37.93%",
39101
+ "deltaType": "POSITIVE",
39102
+ "label": "Initial JS"
39103
+ },
39104
+ {
39105
+ "value": 48866,
39106
+ "displayValue": "47.72KiB",
39107
+ "delta": -16917,
39108
+ "deltaPercentage": -25.71637049,
39109
+ "displayDelta": "-16.52KiB",
39110
+ "displayDeltaPercentage": "-25.72%",
39111
+ "deltaType": "POSITIVE",
39112
+ "label": "Initial CSS"
39113
+ },
39114
+ {
39115
+ "value": 97.21,
39116
+ "displayValue": "97.21%",
39117
+ "delta": 97.21,
39118
+ "deltaPercentage": 100,
39119
+ "displayDelta": "+97.21%",
39120
+ "displayDeltaPercentage": "+100%",
39121
+ "deltaType": "HIGH_NEGATIVE",
39122
+ "label": "Cache Invalidation"
39123
+ },
39124
+ {
39125
+ "value": 1074,
39126
+ "displayValue": "1074",
39127
+ "delta": -72,
39128
+ "deltaPercentage": -6.28272251,
39129
+ "displayDelta": "-72",
39130
+ "displayDeltaPercentage": "-6.28%",
39131
+ "deltaType": "POSITIVE",
39132
+ "label": "Modules"
39133
+ },
39134
+ {
39135
+ "value": 6,
39136
+ "displayValue": "6",
39137
+ "delta": 4,
39138
+ "deltaPercentage": 200,
39139
+ "displayDelta": "+4",
39140
+ "displayDeltaPercentage": "+200%",
39141
+ "deltaType": "HIGH_NEGATIVE",
39142
+ "label": "Duplicate Modules"
39143
+ },
39144
+ {
39145
+ "value": 1.14,
39146
+ "displayValue": "1.14%",
39147
+ "delta": 0.9799999999999999,
39148
+ "deltaPercentage": 612.5,
39149
+ "displayDelta": "+0.98%",
39150
+ "displayDeltaPercentage": "+612.5%",
39151
+ "deltaType": "HIGH_NEGATIVE",
39152
+ "label": "Duplicate Code"
39153
+ },
39154
+ {
39155
+ "value": 12,
39156
+ "displayValue": "12",
39157
+ "delta": 8,
39158
+ "deltaPercentage": 200,
39159
+ "displayDelta": "+8",
39160
+ "displayDeltaPercentage": "+200%",
39161
+ "deltaType": "HIGH_NEGATIVE",
39162
+ "label": "Chunks"
39163
+ },
39164
+ {
39165
+ "value": 26,
39166
+ "displayValue": "26",
39167
+ "delta": 8,
39168
+ "deltaPercentage": 44.44444444,
39169
+ "displayDelta": "+8",
39170
+ "displayDeltaPercentage": "+44.44%",
39171
+ "deltaType": "NEGATIVE",
39172
+ "label": "Assets"
39173
+ },
39174
+ {
39175
+ "value": 146,
39176
+ "displayValue": "146",
39177
+ "delta": 3,
39178
+ "deltaPercentage": 2.0979021,
39179
+ "displayDelta": "+3",
39180
+ "displayDeltaPercentage": "+2.1%",
39181
+ "deltaType": "LOW_NEGATIVE",
39182
+ "label": "Packages"
39183
+ },
39184
+ {
39185
+ "value": 13,
39186
+ "displayValue": "13",
39187
+ "delta": 2,
39188
+ "deltaPercentage": 18.18181818,
39189
+ "displayDelta": "+2",
39190
+ "displayDeltaPercentage": "+18.18%",
39191
+ "deltaType": "NEGATIVE",
39192
+ "label": "Duplicate Packages"
39193
+ }
39194
+ ]
39195
+ },
39196
+ "insights": {
39197
+ "webpack": {
39198
+ "assetsSizeTotal": {
39199
+ "type": "INFO",
39200
+ "data": {
39201
+ "text": "Bundle Size — 2MiB (-3.11%).",
39202
+ "md": "*Bundle Size* — *2MiB* (*-3.11%*).",
39203
+ "info": {
39204
+ "value": 2097917,
39205
+ "displayValue": "2MiB",
39206
+ "delta": -67252,
39207
+ "deltaPercentage": -3.10608548,
39208
+ "displayDelta": "-65.68KiB",
39209
+ "displayDeltaPercentage": "-3.11%",
39210
+ "deltaType": "LOW_POSITIVE"
39211
+ }
39212
+ }
39213
+ },
39214
+ "duplicatePackages": {
39215
+ "type": "WARNING",
39216
+ "data": {
39217
+ "tslib": [
39218
+ "@firebase/app:tslib",
39219
+ "@firebase/util:tslib",
39220
+ "@firebase/component:tslib",
39221
+ "tslib"
39222
+ ],
39223
+ "lodash.throttle": [
39224
+ "lodash.throttle~1",
39225
+ "@bundle-stats/ui:lodash.throttle",
39226
+ "lodash.throttle"
39227
+ ],
39228
+ "object-keys": [
39229
+ "document.contains:object-keys",
39230
+ "object.values:object-keys"
39231
+ ],
39232
+ "react-is": [
39233
+ "recharts:react-is",
39234
+ "orbit-ui-react:react-is",
39235
+ "react-is"
39236
+ ],
39237
+ "@babel/runtime": [
39238
+ "orbit-ui-react:@babel/runtime",
39239
+ "@babel/runtime",
39240
+ "mini-create-react-context:@babel/runtime"
39241
+ ],
39242
+ "hoist-non-react-statics": [
39243
+ "react-router:hoist-non-react-statics",
39244
+ "hoist-non-react-statics"
39245
+ ],
39246
+ "define-properties": [
39247
+ "object.values:define-properties",
39248
+ "document.contains:define-properties"
39249
+ ],
39250
+ "has": [
39251
+ "object.values:has",
39252
+ "has"
39253
+ ]
39254
+ }
39255
+ },
39256
+ "duplicatePackagesV3": {
39257
+ "type": "ERROR",
39258
+ "data": {
39259
+ "text": "Bundle introduced 2 duplicate packages",
39260
+ "packages": {
39261
+ "tslib": [
39262
+ "@firebase/app:tslib",
39263
+ "@firebase/util:tslib",
39264
+ "@firebase/component:tslib",
39265
+ "tslib"
39266
+ ],
39267
+ "lodash.throttle": [
39268
+ "lodash.throttle~1",
39269
+ "@bundle-stats/ui:lodash.throttle",
39270
+ "lodash.throttle"
39271
+ ],
39272
+ "object-keys": [
39273
+ "document.contains:object-keys",
39274
+ "object.values:object-keys"
39275
+ ],
39276
+ "react-is": [
39277
+ "recharts:react-is",
39278
+ "orbit-ui-react:react-is",
39279
+ "react-is"
39280
+ ],
39281
+ "@babel/runtime": [
39282
+ "orbit-ui-react:@babel/runtime",
39283
+ "@babel/runtime",
39284
+ "mini-create-react-context:@babel/runtime"
39285
+ ],
39286
+ "hoist-non-react-statics": [
39287
+ "react-router:hoist-non-react-statics",
39288
+ "hoist-non-react-statics"
39289
+ ],
39290
+ "define-properties": [
39291
+ "object.values:define-properties",
39292
+ "document.contains:define-properties"
39293
+ ],
39294
+ "has": [
39295
+ "object.values:has",
39296
+ "has"
39297
+ ]
39298
+ }
39299
+ }
39300
+ }
39301
+ }
39302
+ }
39258
39303
  }
package/lib/cli.js CHANGED
@@ -9,14 +9,16 @@ const update_notifier_1 = __importDefault(require("update-notifier"));
9
9
  const run_1 = __importDefault(require("./run"));
10
10
  const DEFAULT_OUTPUT_DIR = './dist';
11
11
  const WEEK_IN_MS = 1000 * 60 * 60 * 24 * 7;
12
- async function cli(packageInfo) {
13
- const notifier = (0, update_notifier_1.default)({ pkg: packageInfo, updateCheckInterval: WEEK_IN_MS });
12
+ async function cli(pkg) {
13
+ const notifier = (0, update_notifier_1.default)({ pkg, updateCheckInterval: WEEK_IN_MS });
14
14
  if (notifier.update) {
15
15
  notifier.notify();
16
16
  }
17
- const { demo } = yargs_1.default.parse();
17
+ const { demo } = yargs_1.default.options({ demo: { type: 'boolean', default: false } }).parseSync();
18
18
  if (demo) {
19
19
  await (0, run_1.default)({
20
+ baseline: false,
21
+ compare: false,
20
22
  html: true,
21
23
  json: true,
22
24
  outDir: DEFAULT_OUTPUT_DIR,
@@ -32,44 +34,46 @@ async function cli(packageInfo) {
32
34
  .demandCommand(1, 'Webpack stats file path is required.')
33
35
  .option('out-dir', {
34
36
  description: 'Output directory',
37
+ type: 'string',
35
38
  default: DEFAULT_OUTPUT_DIR,
36
39
  })
37
40
  .option('compare', {
38
41
  description: 'Use local saved stats for comparison',
39
- boolean: true,
42
+ type: 'boolean',
40
43
  default: true,
41
44
  })
42
45
  .option('baseline', {
43
46
  description: 'Save current stats as baseline',
44
- boolean: true,
47
+ type: 'boolean',
45
48
  default: false,
46
49
  })
47
50
  .option('html', {
48
51
  description: 'Save HTML report',
49
- boolean: true,
52
+ type: 'boolean',
50
53
  default: true,
51
54
  })
52
55
  .option('json', {
53
56
  description: 'Save JSON data',
54
- boolean: true,
57
+ type: 'boolean',
55
58
  default: false,
56
59
  })
57
60
  .option('demo', {
58
61
  description: 'Generate demo reports',
62
+ type: 'boolean',
59
63
  default: false,
60
64
  })
61
65
  .alias('d', 'out-dir')
62
66
  .alias('h', 'help')
63
67
  .alias('v', 'version')
64
- .help().argv;
65
- const { compare, baseline, html, json, outDir, _: artifactFilepaths, } = args;
68
+ .help()
69
+ .parseSync();
66
70
  await (0, run_1.default)({
67
- baseline,
68
- compare,
69
- html,
70
- json,
71
- outDir,
72
- artifactFilepaths,
71
+ baseline: args.baseline,
72
+ compare: args.compare,
73
+ html: args.html,
74
+ json: args.json,
75
+ outDir: args.outDir,
76
+ artifactFilepaths: args._,
73
77
  });
74
78
  }
75
79
  exports.default = cli;
package/lib/cli.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"cli.js","sourceRoot":"","sources":["../src/cli.js"],"names":[],"mappings":";;;;;AAAA,gDAAwB;AACxB,kDAA0B;AAC1B,sEAA6C;AAE7C,gDAAwB;AAExB,MAAM,kBAAkB,GAAG,QAAQ,CAAC;AACpC,MAAM,UAAU,GAAG,IAAI,GAAG,EAAE,GAAG,EAAE,GAAG,EAAE,GAAG,CAAC,CAAC;AAE5B,KAAK,UAAU,GAAG,CAAC,WAAW;IAE3C,MAAM,QAAQ,GAAG,IAAA,yBAAc,EAAC,EAAE,GAAG,EAAE,WAAW,EAAE,mBAAmB,EAAE,UAAU,EAAE,CAAC,CAAC;IAEvF,IAAI,QAAQ,CAAC,MAAM,EAAE;QACnB,QAAQ,CAAC,MAAM,EAAE,CAAC;KACnB;IAGD,MAAM,EAAE,IAAI,EAAE,GAAG,eAAK,CAAC,KAAK,EAAE,CAAC;IAE/B,IAAI,IAAI,EAAE;QACR,MAAM,IAAA,aAAG,EAAC;YACR,IAAI,EAAE,IAAI;YACV,IAAI,EAAE,IAAI;YACV,MAAM,EAAE,kBAAkB;YAC1B,iBAAiB,EAAE;gBACjB,cAAI,CAAC,OAAO,CAAC,SAAS,EAAE,4CAA4C,CAAC;gBACrE,cAAI,CAAC,OAAO,CAAC,SAAS,EAAE,6CAA6C,CAAC;aACvE;SACF,CAAC,CAAC;QAEH,OAAO;KACR;IAED,MAAM,IAAI,GAAG,eAAK;SACf,KAAK,CAAC,mCAAmC,CAAC;SAC1C,aAAa,CAAC,CAAC,EAAE,sCAAsC,CAAC;SACxD,MAAM,CAAC,SAAS,EAAE;QACjB,WAAW,EAAE,kBAAkB;QAC/B,OAAO,EAAE,kB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;QACd,WAAW,EAAE,kBAAkB;QAC/B,IAAI,EAAE,SAAS;QACf,OAAO,EAAE,IAAI;KACd,CAAC;SACD,MAAM,CAAC,MAAM,EAAE;QACd,WAAW,EAAE,gBAAgB;QAC7B,IAAI,EAAE,SAAS;QACf,OAAO,EAAE,KAAK;KACf,CAAC;SACD,MAAM,CAAC,MAAM,EAAE;QACd,WAAW,EAAE,uBAAuB;QACpC,IAAI,EAAE,SAAS;QACf,OAAO,EAAE,KAAK;KACf,CAAC;SACD,KAAK,CAAC,GAAG,EAAE,SAAS,CAAC;SACrB,KAAK,CAAC,GAAG,EAAE,MAAM,CAAC;SAClB,KAAK,CAAC,GAAG,EAAE,SAAS,CAAC;SACrB,IAAI,EAAE;SACN,SAAS,EAAE,CAAC;IAEf,MAAM,IAAA,aAAG,EAAC;QACR,QAAQ,EAAE,IAAI,CAAC,QAAQ;QACvB,OAAO,EAAE,IAAI,CAAC,OAAO;QACrB,IAAI,EAAE,IAAI,CAAC,IAAI;QACf,IAAI,EAAE,IAAI,CAAC,IAAI;QACf,MAAM,EAAE,IAAI,CAAC,MAAM;QACnB,iBAAiB,EAAE,IAAI,CAAC,CAAkB;KAC3C,CAAC,CAAC;AACL,CAAC;AA1ED,sBA0EC"}
package/package.json CHANGED
@@ -1,12 +1,11 @@
1
1
  {
2
2
  "name": "bundle-stats",
3
- "version": "4.2.0-beta.1",
3
+ "version": "4.2.0-beta.2",
4
4
  "description": "In-depth bundle analyzer for webpack(bundle size, assets, modules, packages)",
5
5
  "bin": {
6
6
  "bundle-stats": "bin/index.js"
7
7
  },
8
8
  "main": "lib/index.js",
9
- "module": "lib-esm/index.js",
10
9
  "types": "types/index.d.ts",
11
10
  "directories": {
12
11
  "lib": "lib"
@@ -15,11 +14,11 @@
15
14
  "node": ">= 14.0"
16
15
  },
17
16
  "scripts": {
18
- "build": "npm run build-lib && npm run build-esm",
19
- "build-lib": "rm -fr ./lib && ../../node_modules/.bin/tsc --rootDir ./src --project tsconfig.lib.json --outDir ./lib",
20
- "build-esm": "rm -fr ./lib-esm && rm -fr ./types && ../../node_modules/.bin/tsc --rootDir ./src --project tsconfig.esm.json --outDir ./lib-esm",
17
+ "build": "rm -fr ./lib && ../../node_modules/.bin/tsc --rootDir ./src --project tsconfig.lib.json --outDir ./lib",
21
18
  "lint": "../../node_modules/.bin/eslint . --ext .js",
22
- "test": "jest --passWithNoTests"
19
+ "serve-demo": "./bin/index.js --demo && http-server dist",
20
+ "test": "jest --passWithNoTests test/unit",
21
+ "test:e2e": "playwright test"
23
22
  },
24
23
  "keywords": [
25
24
  "webpack",
@@ -48,10 +47,10 @@
48
47
  },
49
48
  "homepage": "https://github.com/relative-ci/bundle-stats/blob/master/packages/cli#readme",
50
49
  "dependencies": {
51
- "@bundle-stats/cli-utils": "^4.2.0-beta.1",
52
- "@bundle-stats/plugin-webpack-filter": "^4.2.0-beta.1",
53
- "@bundle-stats/plugin-webpack-validate": "^4.2.0-beta.1",
54
- "@bundle-stats/utils": "^4.2.0-beta.1",
50
+ "@bundle-stats/cli-utils": "^4.2.0-beta.2",
51
+ "@bundle-stats/plugin-webpack-filter": "^4.2.0-beta.2",
52
+ "@bundle-stats/plugin-webpack-validate": "^4.2.0-beta.2",
53
+ "@bundle-stats/utils": "^4.2.0-beta.2",
55
54
  "boxen": "^5.0.0",
56
55
  "core-js": "^3.21.0",
57
56
  "fs-extra": "^11.0.0",
@@ -61,10 +60,16 @@
61
60
  "yargs": "^17.4.0"
62
61
  },
63
62
  "devDependencies": {
64
- "@types/fs-extra": "^9.0.13",
63
+ "@argos-ci/cli": "^0.4.3",
64
+ "@argos-ci/playwright": "^0.0.1",
65
+ "@playwright/test": "^1.29.2",
66
+ "@types/fs-extra": "^11.0.0",
65
67
  "@types/listr": "^0.14.4",
66
- "jest": "29.3.1",
68
+ "@types/yargs": "^17.0.20",
69
+ "http-server": "^14.1.1",
70
+ "jest": "29.4.0",
71
+ "playwright": "^1.29.2",
67
72
  "typescript": "4.9.4"
68
73
  },
69
- "gitHead": "c69fdcf2c8b40118710b49cfa973e820e4880242"
74
+ "gitHead": "71463489365dbe443e44ffb6260701fc6e0aea1b"
70
75
  }