dev: change webpack config to use asset modules instead of custom loaders (#34649)

- asset modules are a new webpack 5 feature that handles inlining or extracting resources
This commit is contained in:
RJ 2022-09-13 17:40:56 +08:00 committed by GitHub
parent a49f23abfd
commit bae061a421
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 5 additions and 1 deletions

View File

@ -129,7 +129,7 @@ const webpackConfig = {
{ test: /\.md$/, use: 'raw-loader' }, { test: /\.md$/, use: 'raw-loader' },
{ {
test: /\.(png|jpe?g|gif|svg|eot|ttf|woff|woff2)$/, test: /\.(png|jpe?g|gif|svg|eot|ttf|woff|woff2)$/,
loader: 'url-loader', type: 'asset',
}, },
...styleConfig.rules, ...styleConfig.rules,
], ],

View File

@ -0,0 +1,4 @@
Significance: minor
Type: dev
change webpack config to use asset modules instead of custom loaders