From 0bf3ebfe295b1f9f05f022c68ce1d124acb70eb0 Mon Sep 17 00:00:00 2001 From: Ricardo Arturo Cabral Mejia Date: Mon, 31 Jan 2022 22:00:52 +0000 Subject: [PATCH] chore: output to dist folder --- .gitignore | 1 + webpack.config.js | 10 ++++++++-- 2 files changed, 9 insertions(+), 2 deletions(-) diff --git a/.gitignore b/.gitignore index f138991..2274cf0 100644 --- a/.gitignore +++ b/.gitignore @@ -2,3 +2,4 @@ yarn.lock node_modules *.wasm out.js +dist diff --git a/webpack.config.js b/webpack.config.js index ae2584e..fea9615 100644 --- a/webpack.config.js +++ b/webpack.config.js @@ -1,10 +1,11 @@ const path = require('path') +const HtmlWebpackPlugin = require('html-webpack-plugin') module.exports = { mode: 'development', entry: './main.js', output: { - path: __dirname, + path: `${__dirname}/dist`, filename: 'out.js' }, experiments: {asyncWebAssembly: true}, @@ -17,5 +18,10 @@ module.exports = { stream: 'readable-stream/readable.js', crypto: false } - } + }, + plugins: [ + new HtmlWebpackPlugin({ + template: 'index.html' + }) + ], }