Skip to content

Commit e0262a1

Browse files
committed
Set root default again
1 parent 675dcdc commit e0262a1

3 files changed

Lines changed: 4 additions & 0 deletions

File tree

index.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,7 @@ const formatBytes = (bytes) => {
1616

1717
const analyze = (bundle, opts = {}, format = false) => {
1818
let { root, limit, filter } = opts;
19+
root = root || (process && process.cwd ? process.cwd() : null);
1920
let deps = {};
2021
let entrySize;
2122
let bundleSize = 0;

module.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@ const formatBytes = (bytes) => {
1414

1515
export const analyze = (bundle, opts = {}, format = false) => {
1616
let { root, limit, filter } = opts
17+
root = root || (process && process.cwd ? process.cwd() : null)
1718
let deps = {}
1819
let entrySize
1920
let bundleSize = 0

package.json

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,7 @@
1919
"keywords": [
2020
"rollup",
2121
"plugin",
22+
"config",
2223
"import",
2324
"bundle",
2425
"file",
@@ -27,6 +28,7 @@
2728
"metrics",
2829
"analysis",
2930
"analyze",
31+
"analyzer",
3032
"bloat"
3133
],
3234
"author": "Andrew Carpenter (https://github.com/doesdev)",

0 commit comments

Comments
 (0)