const options =
{
autoInstall: false,
contentHash: false,
hmr: reload,
logLevel: 1,
outDir: `${__dirname}/../build`,
publicUrl: './',
scopeHoist: true,
sourceMaps: debug,
watch
};
Shouldn't throw an error.
Cannot read property 'length' of undefined
at JSConcatPackager.addAsset (/project/node_modules/parcel-bundler/src/packagers/JSConcatPackager.js:184:21)
at Bundle._addDeps (/project/node_modules/parcel-bundler/src/Bundle.js:250:20)
at Bundle._package (/project/node_modules/parcel-bundler/src/Bundle.js:219:18)
at async Promise.all (index 0)
at async Bundle.package (/project/node_modules/parcel-bundler/src/Bundle.js:202:5)
at async Promise.all (index 1)
at async Bundle.package (/project/node_modules/parcel-bundler/src/Bundle.js:202:5)
at async Bundler.bundle (/project/node_modules/parcel-bundler/src/Bundler.js:325:27)
(node:48797) UnhandledPromiseRejectionWarning: TypeError: Cannot read property 'length' of undefined
at JSConcatPackager.addAsset (/project/node_modules/parcel-bundler/src/packagers/JSConcatPackager.js:184:21)
at Bundle._addDeps (/project/node_modules/parcel-bundler/src/Bundle.js:250:20)
at Bundle._package (/project/node_modules/parcel-bundler/src/Bundle.js:219:18)
at async Promise.all (index 0)
at async Bundle.package (/project/node_modules/parcel-bundler/src/Bundle.js:202:5)
at async Promise.all (index 1)
at async Bundle.package (/project/node_modules/parcel-bundler/src/Bundle.js:202:5)
at async Bundler.bundle (/project/node_modules/parcel-bundler/src/Bundler.js:325:27)
set scropeHoist to false.
| Software | Version(s) |
| ---------------- | ---------- |
| Parcel |1.12.3
| Node |12.8.0
| npm/Yarn |6.10.2
| Operating System |macOS 10.14.6
This issue has been automatically marked as stale because it has not had recent activity. It will be closed in 14 days if no further activity occurs.
Same issue with:
Parcel 1.12.4
Node 12.17.0
npm 6.14.5
OS Ubuntu 18.04
@Anton-4 does this still occur with Parcel 2, if it does please open a new issue as this issue is quite old and nobody ever really provided a reproducable or anything we can use to debug this.