wasmweb-sample/www/webpack.config.js

28 lines
538 B
JavaScript
Raw Normal View History

2020-08-20 10:54:33 +07:00
const CopyWebpackPlugin = require("copy-webpack-plugin");
const path = require('path');
module.exports = {
2020-08-20 11:42:43 +07:00
entry: "./bootstrap.ts",
devtool: 'inline-source-map',
module: {
rules: [
{
test: /\.tsx?$/,
use: 'ts-loader',
exclude: /node_modules/,
},
],
},
resolve: {
extensions: [ '.tsx', '.ts', '.js' ],
},
2020-08-20 10:54:33 +07:00
output: {
path: path.resolve(__dirname, "dist"),
2020-08-20 11:42:43 +07:00
filename: 'bundle.js',
2020-08-20 10:54:33 +07:00
},
mode: "development",
plugins: [
new CopyWebpackPlugin(['index.html'])
],
};