It throws an error, I am using latest CRA version.
Error message:
Build app and generate report...
analyzing... [================== ][92%][0.7 seconds] - chunk asset optimizationError parsing bundle asset "Z:\Repos\project\build\static\js\main.4618758d.chunk.js": no such file
Error parsing bundle asset "Z:\Repos\project\build\static\js\runtime-main.0a7f180f.js": no such file
No bundles were parsed. Analyzer will show only original module sizes from stats file.
Webpack Bundle Analyzer saved report to Z:\Repos\project\build\report.html
Build completed in 0.773s
(node:15352) UnhandledPromiseRejectionWarning: Error: ./src/index.tsx
Module build failed (from ./node_modules/react-scripts/node_modules/babel-loader/lib/index.js):
Error [ERR_PACKAGE_PATH_NOT_EXPORTED]: Package subpath './plugin-bugfixes' is not defined by "exports" in Z:\Repos\project\node_modules\@babel\compat-data\package.json
at applyExports (internal/modules/cjs/loader.js:524:9)
at resolveExports (internal/modules/cjs/loader.js:541:12)
at Function.Module._findPath (internal/modules/cjs/loader.js:661:22)
at Function.Module._resolveFilename (internal/modules/cjs/loader.js:963:27)
at Function.Module._load (internal/modules/cjs/loader.js:859:27)
at Module.require (internal/modules/cjs/loader.js:1036:19)
at require (internal/modules/cjs/helpers.js:72:18)
at Object.<anonymous> (Z:\Repos\project\node_modules\babel-preset-react-app\node_modules\@babel\preset-env\lib\plugins-compat-data.js:10:46)
at Module._compile (internal/modules/cjs/loader.js:1147:30)
at Object.Module._extensions..js (internal/modules/cjs/loader.js:1167:10)
at Z:\Repos\project\node_modules\cra-bundle-analyzer\src\index.js:66:23
at finalCallback (Z:\Repos\project\node_modules\webpack\lib\Compiler.js:257:39)
at Z:\Repos\project\node_modules\webpack\lib\Compiler.js:273:13
at _next2 (eval at create (Z:\Repos\project\node_modules\tapable\lib\HookCodeFactory.js:33:10), <anonymous>:14:1)
at eval (eval at create (Z:\Repos\project\node_modules\tapable\lib\HookCodeFactory.js:33:10), <anonymous>:40:1)
at Immediate.<anonymous> (Z:\Repos\project\node_modules\webpack-bundle-analyzer\lib\BundleAnalyzerPlugin.js:79:13)
at Generator.next (<anonymous>)
at asyncGeneratorStep (Z:\Repos\project\node_modules\webpack-bundle-analyzer\lib\BundleAnalyzerPlugin.js:3:103)
at _next (Z:\Repos\project\node_modules\webpack-bundle-analyzer\lib\BundleAnalyzerPlugin.js:5:194)
at processTicksAndRejections (internal/process/task_queues.js:97:5)
(node:15352) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a
promise which was not handled with .catch(). To terminate the node process on unhandled promise rejection, use the CLI flag `--unhandled-rejections=strict` (see https://nodejs.org/api/cli.html#cli_unhandled_rejections_mode). (rejection id: 1)
(node:15352) [DEP0018] DeprecationWarning: Unhandled promise rejections are deprecated. In the future, promise rejections that are not handled will terminate the Node.js process with a non-zero exit code.
Hi @bartlomiejzuber, I've tried with the latest version of CRA, and it works fine. I can't reproduce your problem. If you can isolate this issue in a simple project, I will have a look.
It throws an error, I am using latest CRA version.
Error message:
Package.json
Is there something I miss ? I've installed and ran this tool as suggested inside this repo readme file.