当前位置:网站首页>vite打包构建时 @charset utf-8警告问题处理;
vite打包构建时 @charset utf-8警告问题处理;
2022-06-25 23:13:00 【Colesyn L.】
vite打包构建时 @charset utf-8警告问题处理;
今天在vite打包时出现了个警告 虽然不影响用户交互但是我还是觉得应该处理一下;
报错如下
解决办法
在 vite.config.ts中加入css/和resolve/plugins/server同级即可
css: {
postcss: {
plugins: [
{
postcssPlugin: 'internal:charset-removal',
AtRule: {
charset: atRule => {
if (atRule.name === 'charset') {
atRule.remove();
}
},
},
},
],
},
},
再次打包发现警告已经没了
边栏推荐
- Flex & Bison 开始
- 经典面试题之老鼠试药与汉明码
- Anaconda beginner's notes
- [image detection] vascular tracking and diameter estimation based on Gaussian process and Radon transform with matlab code
- Daily question: the difference between threads and processes
- ASP.NET cache缓存的用法
- Web學習之TypeScript
- [learn FPGA programming from scratch -44]: vision chapter - integrated circuit helps high-quality development in the digital era -1- main forms of integrated circuit chips
- ADC acquisition noise and comparison between RMS filter and Kalman filter
- Wireshark's analysis of IMAP packet capturing
猜你喜欢

Msp430f5529lp official board (red) can not debug the problem

Nacos registry

Stream data

Blob

Vscode shortcut

Flink reports error: a JNI error has occurred, please check your installation and try again

Ad20 (Altium designer) PCB highlight network

STM32 uses SPI mode to drive TFT-LCD optimization code of hx8347 scheme

Compile the telegraph desktop side (tdesktop) using vs2022

STL tutorial 5-basic concepts of STL and the use of string and vector
随机推荐
Template engine - FreeMarker first experience
Compile the telegraph desktop side (tdesktop) using vs2022
Chapter VI exercises (678) [microcomputer principles] [exercises]
在线小工具分享(不定时更新,当前数量:2)
Compiler Telegram Desktop end (tdesktop) en utilisant vs2022
Middle order clue binary tree
The maze of God's perspective in robot vision
mysql错误代码2003的解决办法
Case: drawing Matplotlib dynamic graph
马斯克 VS 乔布斯,谁是21世纪最伟大的创业家
Qt优秀开源项目之九:qTox
Why is it best to use equals for integer comparisons
1-10vmware builds customized network architecture
Msp430f5529lp official board (red) can not debug the problem
Wireshark's analysis of IMAP packet capturing
Cartoon shader
Px4 system terminal for pixhawk
Endnote IEEE TRANSACTIONS ON INDUSTRIAL ELECTRONICS/TIE/TPEL 参考文献格式模板
返回值为Object型方法调用equals()
Sqlserver is case sensitive