...
|
...
|
@@ -39,6 +39,9 @@ const dist = { |
|
|
font: `${distRoot}/assets/font`
|
|
|
};
|
|
|
|
|
|
// webpack 内嵌的样式中的雪碧图,写文件的时候会有冲突,这边使用单实例
|
|
|
let postcssSprites;
|
|
|
|
|
|
/**
|
|
|
* postcss plugins for both dev and pro
|
|
|
* @parem et Symbol
|
...
|
...
|
@@ -93,9 +96,12 @@ const postcssPlugin = (et) => { |
|
|
});
|
|
|
}
|
|
|
|
|
|
if (!postcssSprites) {
|
|
|
postcssSprites = require('postcss-sprites').default(sprites);
|
|
|
}
|
|
|
plugins = [
|
|
|
require('precss'),
|
|
|
require('postcss-sprites').default(sprites),
|
|
|
postcssSprites,
|
|
|
require('postcss-assets')(assets),
|
|
|
require('postcss-calc'),
|
|
|
require('postcss-pxtorem')({
|
...
|
...
|
|