Closed peerless-hero closed 10 months ago
升级 3.2.1,使用 viteNext: true配置,可以消除
createHtmlPlugin({
// 启用 Vite 最新语法模式
viteNext: true,
// 在这里写 entry 后,你将不需要在 `index.html` 内添加 script 标签,原有标签需要删除
entry: 'src/main.ts',
// 是否压缩 html
minify: true,
// 需要注入 index.html ejs 模版的数据
inject: {
data: { title: '动态标题', buildTime: new Date().toLocaleString() },
},
})
@peerless-hero The issue you are describing still exists in the latest release 3.2.1, but it was already fixed & merged to the main branch a few days ago. A release is on the way in the coming days.
@cctvhe11 @Ace627, the viteNext
property has been removed, so when the next release is out, you may remove it from your configuration
EDIT
: release 3.2.2 is out
@qeleb Ok,I got it,thank you。
@qeleb 感谢你的及时跟进。 Thank you for your timely follow-up.
vite具体版本:5.0.11 vite打包警告:
希望尽快适配以消除警告。