build: remove devServer from misc config
This commit is contained in:
+1
-11
@@ -189,8 +189,6 @@ const browserConfig = (/*env, argv*/) => {
|
|||||||
};
|
};
|
||||||
|
|
||||||
const miscConfig = (/*env, argv*/) => {
|
const miscConfig = (/*env, argv*/) => {
|
||||||
const isDevServer = process.env.WEBPACK_SERVE;
|
|
||||||
|
|
||||||
/** @type {import('webpack').Configuration['entry']} */
|
/** @type {import('webpack').Configuration['entry']} */
|
||||||
const entry = {
|
const entry = {
|
||||||
misc: "./src/misc.ts",
|
misc: "./src/misc.ts",
|
||||||
@@ -201,7 +199,7 @@ const miscConfig = (/*env, argv*/) => {
|
|||||||
target: "web",
|
target: "web",
|
||||||
mode: "production",
|
mode: "production",
|
||||||
cache: {
|
cache: {
|
||||||
type: isDevServer ? "memory" : "filesystem",
|
type: "filesystem"
|
||||||
},
|
},
|
||||||
resolve: {
|
resolve: {
|
||||||
fallback: { crypto: false },
|
fallback: { crypto: false },
|
||||||
@@ -217,14 +215,6 @@ const miscConfig = (/*env, argv*/) => {
|
|||||||
publicPath: "/",
|
publicPath: "/",
|
||||||
},
|
},
|
||||||
|
|
||||||
devServer: {
|
|
||||||
compress: true,
|
|
||||||
port: 9990,
|
|
||||||
open: false,
|
|
||||||
static: __dirname,
|
|
||||||
//publicPath: "/"
|
|
||||||
},
|
|
||||||
|
|
||||||
plugins: [
|
plugins: [
|
||||||
new webpack.NormalModuleReplacementPlugin(/^node:*/, (resource) => {
|
new webpack.NormalModuleReplacementPlugin(/^node:*/, (resource) => {
|
||||||
switch (resource.request) {
|
switch (resource.request) {
|
||||||
|
|||||||
Reference in New Issue
Block a user