Authored by ccbikai(👎🏻🍜)

打包雪碧图

... ... @@ -56,8 +56,8 @@ const postcssPlugin = (et) => {
return Promise.reject();
},
groupBy(file) {
var group = file.url.split('/')[1];
var entry = path.basename(file.styleFilePath, '.css');
let group = file.url.split('/')[1];
let entry = path.basename(file.styleFilePath);
file.retina = true;
file.radio = 2;
... ... @@ -66,7 +66,7 @@ const postcssPlugin = (et) => {
group = entry + '.' + group;
}
return group ? Promise.resolve(group) : Promise.reject(group);
return group ? Promise.resolve(group) : Promise.reject('yoho');
}
},
assets,
... ...