File tree Expand file tree Collapse file tree 1 file changed +6
-6
lines changed Expand file tree Collapse file tree 1 file changed +6
-6
lines changed Original file line number Diff line number Diff line change @@ -67,9 +67,9 @@ module.exports = {
67
67
module .exports = {
68
68
build: {
69
69
extend : (config ) => {
70
- const svgRule = config .module .rules .find (rule => rule .loader === ' url-loader ' );
70
+ const svgRule = config .module .rules .find (rule => rule .test . test ( ' .svg ' ) );
71
71
72
- svgRule .test = / \. (png| jpe? g| gif)$ / ;
72
+ svgRule .test = / \. (png| jpe? g| gif| webp )$ / ;
73
73
74
74
config .module .rules .push ({
75
75
test: / \. svg$ / ,
@@ -182,9 +182,9 @@ module.exports = {
182
182
module .exports = {
183
183
build: {
184
184
extend : (config ) => {
185
- const svgRule = config .module .rules .find (rule => rule .loader === ' url-loader ' );
185
+ const svgRule = config .module .rules .find (rule => rule .test . test ( ' .svg ' ) );
186
186
187
- svgRule .test = / \. (png| jpe? g| gif)$ / ;
187
+ svgRule .test = / \. (png| jpe? g| gif| webp )$ / ;
188
188
189
189
config .module .rules .push ({
190
190
test: / \. svg$ / ,
@@ -278,9 +278,9 @@ const { basename } = require('path');
278
278
module .exports = {
279
279
build: {
280
280
extend : (config ) => {
281
- const svgRule = config .module .rules .find (rule => rule .loader === ' url-loader ' );
281
+ const svgRule = config .module .rules .find (rule => rule .test . test ( ' .svg ' ) );
282
282
283
- svgRule .test = / \. (png| jpe? g| gif)$ / ;
283
+ svgRule .test = / \. (png| jpe? g| gif| webp )$ / ;
284
284
285
285
config .module .rules .push ({
286
286
test: / \. svg$ / ,
You can’t perform that action at this time.
0 commit comments