mirror of
https://github.com/alex8088/electron-vite.git
synced 2026-06-04 21:05:23 +08:00
fix: chunk filename is wrong in ES mode
This commit is contained in:
parent
5333d5216a
commit
371b650d71
@ -254,7 +254,9 @@ export function electronPreloadConfigPresetPlugin(options?: ElectronPluginOption
|
||||
})
|
||||
} else {
|
||||
config.build.rolldownOptions!.output!['entryFileNames'] = '[name].mjs'
|
||||
config.build.rolldownOptions!.output!['chunkFileNames'] = '[name]-[hash].mjs'
|
||||
config.build.rolldownOptions!.output!['chunkFileNames'] = config.build.lib
|
||||
? '[name]-[hash].mjs'
|
||||
: path.posix.join(build.assetsDir || defaultConfig.build.assetsDir, '[name]-[hash].mjs')
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user