diff --git a/src/node/plugin.ts b/src/node/plugin.ts index 667258fa..6cfc02f6 100644 --- a/src/node/plugin.ts +++ b/src/node/plugin.ts @@ -346,6 +346,10 @@ export async function createVitePressPlugin( bundle[name + '-lean'] = { ...chunk, fileName: chunk.fileName.replace(/\.js$/, '.lean.js'), + preliminaryFileName: chunk.preliminaryFileName.replace( + /\.js$/, + '.lean.js' + ), code: chunk.code.replace(staticStripRE, `""`) }