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 have an simple index file that exposes various tsx components and interfaces that looks like so:
export * from './BatchesApi';
export * from './common';
export * from './GetBatches';
export * from './GetBatchStats';
export * from './PinBatch';
export * from './ScheduleBatches';
export * from './TransitionBatchEvent';
Unfortunately, when I attempt to load the page, the output bundle.js file is erroring on this code with the error: _common__WEBPACK_IMPORTED_MODULE_1__ is undefined
If I dive into the bundled code, it is clear why. The bundle generated by webpack 5 is attempting to export the various modules prior to importing them - and so of course the variables in question are undefined...
Bug report
What is the current behavior?
I have an simple index file that exposes various tsx components and interfaces that looks like so:
Unfortunately, when I attempt to load the page, the output bundle.js file is erroring on this code with the error:
_common__WEBPACK_IMPORTED_MODULE_1__ is undefined
If I dive into the bundled code, it is clear why. The bundle generated by webpack 5 is attempting to export the various modules prior to importing them - and so of course the variables in question are undefined...
If the current behavior is a bug, please provide the steps to reproduce.
My webpack.common.js file is as so:
And my webpack.develoment.js file is like so:
What is the expected behavior?
Webpack should be able to handle
export * from <file>;
statements properly, first importing and then exporting.Other relevant information:
webpack version: ^5.90.0
Node.js version: 16.16.0
Operating System: Ubuntu running in WSL2 on Windows 11
The text was updated successfully, but these errors were encountered: