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
Bundlewatch throws an exception if there is no package.json in the current directory, even when passing --config
If the current behavior is a bug, please provide the steps to reproduce.
From a directory with no package.json, run /usr/local/bin/npx bundlewatch --config foo.json. The following exception will occur:
TypeError: Cannot read property 'bundlewatch' of undefined
at determineConfig (/Users/drogers/.npm/_npx/3805/lib/node_modules/bundlewatch/lib/bin/determineConfig.js:70:36)
at main (/Users/drogers/.npm/_npx/3805/lib/node_modules/bundlewatch/lib/bin/index.js:51:47)
at mainSafe (/Users/drogers/.npm/_npx/3805/lib/node_modules/bundlewatch/lib/bin/index.js:102:29)
at Object.<anonymous> (/Users/drogers/.npm/_npx/3805/lib/node_modules/bundlewatch/lib/bin/index.js:149:1)
at Module._compile (internal/modules/cjs/loader.js:1251:30)
at Object.Module._extensions..js (internal/modules/cjs/loader.js:1272:10)
at Module.load (internal/modules/cjs/loader.js:1100:32)
at Function.Module._load (internal/modules/cjs/loader.js:962:14)
at Function.executeUserEntryPoint [as runMain] (internal/modules/run_main.js:72:12)
at /usr/local/lib/node_modules/npm/node_modules/libnpx/index.js:268:14
[FATAL] Uncaught exception
What is the expected behavior?
The missing package.json should be ignored, and the proviced config file used.
If this is a feature request, what is motivation or use case for changing the behavior?
Please mention other relevant information such as the browser version, Node.js version, bundlewatch version, and Operating System.
The text was updated successfully, but these errors were encountered:
Do you want to request a feature or report a bug?
Bug report.
What is the current behavior?
Bundlewatch throws an exception if there is no package.json in the current directory, even when passing
--config
If the current behavior is a bug, please provide the steps to reproduce.
package.json
, run/usr/local/bin/npx bundlewatch --config foo.json
. The following exception will occur:What is the expected behavior?
The missing
package.json
should be ignored, and the proviced config file used.If this is a feature request, what is motivation or use case for changing the behavior?
Please mention other relevant information such as the browser version, Node.js version, bundlewatch version, and Operating System.
The text was updated successfully, but these errors were encountered: