乐趣区

webpack-vuecli3-压缩图片

webpack vue-cli3 压缩图片

yarn add image-webpack-loader
config.module.rules.push({test: /\.(png|jpe?g|gif|svg)(\?.*)?$/,
    use:[{
        loader: 'image-webpack-loader'
        options: {bypassOnDebug: true}
    }]
})
退出移动版