You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I am getting ENOENT the first time I try to create a baseline file:
npx bundle-stats --baseline generated/bundle-size/webpack-stats.json
✔ Read Webpack stats files
↓ Baseline stats file is missing, see "baseline" option. [SKIPPED]
✖ ENOENT: no such file or directory, open '/Users/wolsph/Projects…
◼ Process data
◼ Generate reports
◼ Save reports
ENOENT: no such file or directory, open '/Users/wolsph/Projects/shop-next/node_modules/.cache/bundle-stats/baseline.json'
However, if I create an empty directory first then things are happier:
❯ mkdir -p node_modules/.cache/bundle-stats
❯ npx bundle-stats --baseline generated/bundle-size/webpack-stats.json
✔ Read Webpack stats files
↓ Baseline stats file is missing, see "baseline" option. [SKIPPED]
✔ Write baseline data (node_modules/.cache/bundle-stats/baseline.…
✔ Process data
✔ Generate reports
✔ Save reports
┌─────────────────────────────────────┐
│ │
│ Bundle Size — 18.39MiB (+100%). │
│ │
└─────────────────────────────────────┘
Artifacts:
- dist/bundle-stats.html
The text was updated successfully, but these errors were encountered:
philwolstenholme
changed the title
Writing to baseline file seems to fail the first time due to missing file (because it's not been created yet)
Writing to baseline file seems to fail the first time due to missing directory
Nov 12, 2024
There's a chance this directory was actually created at some point but then I did a rm -rf node_modules/.cache/bundle-stats while experimenting, unfortunately I can't remember. I'd suggest creating the directory if it's empty though?
I am getting
ENOENT
the first time I try to create a baseline file:However, if I create an empty directory first then things are happier:
The text was updated successfully, but these errors were encountered: