打包支持
This commit is contained in:
@@ -3,6 +3,7 @@ const rules = require('./webpack.rules.js');
|
||||
const HtmlWebpackPlugin = require('html-webpack-plugin');
|
||||
const CpWebpackPlugin = require('cp-webpack-plugin');
|
||||
const { CleanWebpackPlugin } = require('clean-webpack-plugin');
|
||||
const zxingReaderWasm = require.resolve('zxing-wasm/reader/zxing_reader.wasm');
|
||||
|
||||
const output = path.resolve('./dist');
|
||||
|
||||
@@ -29,6 +30,7 @@ const config = {
|
||||
}),
|
||||
new CpWebpackPlugin([
|
||||
{ from: path.resolve('./types'), to: path.resolve('./dist') },
|
||||
{ from: zxingReaderWasm, to: path.resolve('./dist/lib/reader.wasm') },
|
||||
])
|
||||
],
|
||||
devtool: 'cheap-module-souce-map',
|
||||
|
||||
Reference in New Issue
Block a user