Fix mojibake (#7073)

Add charset preamble to generated css
This commit is contained in:
Andrew Henry 2023-09-20 18:01:30 -07:00 committed by GitHub
parent b8949db767
commit 05c7a81630
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -110,6 +110,12 @@ const config = {
new MiniCssExtractPlugin({
filename: '[name].css',
chunkFilename: '[name].css'
}),
// Add a UTF-8 BOM to CSS output to avoid random mojibake
new webpack.BannerPlugin({
test: /.*Theme\.css$/,
raw: true,
banner: '@charset "UTF-8";',
})
],
module: {