insert-weui-css-to-independent-plugin.js 643 字节
Newer Older
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20
@import
'weui-miniprogram/weui-wxss/dist/style/weui.wxss';

class InjectWeuiCssToIndependentPlugin {
    apply (compiler) {
        compiler.hooks.emit.tapPromise('InjectWeuiCssToIndependentPlugin', compilation => {
            return new Promise((resolve, reject) => {
                try {
                    const thisCompilationAssets = compilation.assets;
                    resolve();
                } catch (e) {
                    console.error('independent.error', 'InjectWeuiCssToIndependentPlugin', e);
                    reject(e);
                }
            });
        });
    }
}

module.exports = InjectMainCssToIndepe;