Fixed webpack configuration JS style.

This commit is contained in:
Harrison Deng 2022-04-15 15:34:43 -05:00
parent a6a5f75b82
commit 0ad9dd9008
3 changed files with 7 additions and 7 deletions

View File

@ -10,7 +10,7 @@ export default {
}, },
{ {
test: /\.css$/i, test: /\.css$/i,
use: ['style-loader', 'css-loader'], use: ["style-loader", "css-loader"],
} }
] ]
}, },

View File

@ -1,13 +1,13 @@
import merge from "webpack-merge"; import merge from "webpack-merge";
import webpackCommon from "./webpack.common"; import webpackCommon from "./webpack.common";
devConfig = { const devConfig = {
mode: "development", mode: "development",
devtools: "inline-source-map", devtools: "inline-source-map",
devServer: { devServer: {
static: "./dist" static: "./dist"
} }
} };
export default merge(webpackCommon, devConfig); export default merge(webpackCommon, devConfig);

View File

@ -1,12 +1,12 @@
import merge from "webpack-merge" import merge from "webpack-merge";
import webpackCommon from "./webpack.common" import webpackCommon from "./webpack.common";
prodConfig = { const prodConfig = {
mode: "production", mode: "production",
output: { output: {
filename: "[name].js", filename: "[name].js",
path: "./public" path: "./public"
} }
} };
export default merge(webpackCommon, prodConfig); export default merge(webpackCommon, prodConfig);