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
hi @evanw, I know this has been brought up before in #16 and various other threads (#661, #453, #322, #56), but I wanted to ensure the dead code elimination is covered when using dynamic imports.
More precisely, I want to ensure below test case from tooling.report is covered.
This test bundles two modules - an entry module, and a utils.js module it dynamically imports to create a split point. The dynamically imported module has two exports, but only the logCaps export is used.
index.js
(asyncfunction(){const{ logCaps }=awaitimport('./utils.js');logCaps('This is index');})();
hi @evanw, I know this has been brought up before in #16 and various other threads (#661, #453, #322, #56), but I wanted to ensure the dead code elimination is covered when using dynamic imports.
More precisely, I want to ensure below test case from tooling.report is covered.
This test bundles two modules - an entry module, and a
utils.js
module it dynamically imports to create a split point. The dynamically imported module has two exports, but only thelogCaps
export is used.index.js
utils.js
Expected Output:
Once built for production, the
thisIsNeverCalled
function fromutils.js
should not be present in the resulting bundle(s).Output as of
v0.8.39
of esbuild:The text was updated successfully, but these errors were encountered: