silver-fang-mini-game/www/webpack.config.js

36 lines
672 B
JavaScript
Raw Normal View History

2024-05-01 21:24:21 +03:00
const CopyWebpackPlugin = require("copy-webpack-plugin");
const path = require('path');
module.exports = {
2024-09-28 10:50:10 +03:00
entry: "./bootstrap.ts",
devtool: 'inline-source-map',
module: {
rules: [
{
test: /\.ts$/,
use: 'ts-loader',
exclude: /node_modules/,
},
],
},
resolve: {
extensions: ['.ts', '.js'],
},
2024-05-01 21:24:21 +03:00
output: {
path: path.resolve(__dirname, "dist"),
filename: "bootstrap.js",
},
mode: "development",
plugins: [
new CopyWebpackPlugin({ patterns: ['index.html'] })
],
experiments: {
asyncWebAssembly: true,
},
devServer: {
static: {
directory: path.join(__dirname),
},
}
};