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
When a main package imports the packages
And bundle it all with
# parcel build -o build index.js --experimental-scope-hoisting --no-minify Then parcel change the variables name of the rollup build correctly as it does for ts build
When a main package imports the packages
And bundle it all with
# parcel build -o build index.js --experimental-scope-hoisting --no-minify Then parcel change the variables name of the rollup build incorrectly
And runtime throw exception of ReferenceError
💁 Possible Solution
you can see from the example
that the problem occurs when doing the export in one line.
export class failurtestHositingRollup2 {
static create() {
return new failurtestHositingRollup2();
}
};
export default class failurtestHositingRollup {
static create() {
return new failurtestHositingRollup();
}
}
The console.log in that example outputs 1 reference to Test (the export declaration) when it should output 2 (including the reference in create). If you comment out the call to path.scope.crawl() however, it does output 2 correctly, so something about calling crawl again is messing it up. I tried removing our call to crawl in the scope hoisting code, but that broke other tests. Not sure what's going on there.
🐛 bug report
in the following example you can see a problem with --experimental-scope-hoisting when using rollup build cjs
🤔 Expected Behavior
Given a project with lerna and multiple packages
😯 Current Behavior
Given a project with lerna and multiple packages
💁 Possible Solution
you can see from the example
that the problem occurs when doing the export in one line.
💻 Code Sample
parcel bundle with ts import build:
parcel bundle with rollup import build:
🌍 Your Environment
The text was updated successfully, but these errors were encountered: