From 7e3e710e8c17d1d1280d5ed2ee90e9b1742b65bc Mon Sep 17 00:00:00 2001 From: jaywcjlove <398188662@qq.com> Date: Fri, 24 Nov 2023 00:05:41 +0800 Subject: [PATCH] chore: fix failed to parse source map issue. --- www/.kktrc.ts | 5 +++++ www/package.json | 2 +- 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/www/.kktrc.ts b/www/.kktrc.ts index b694972d9..1dc063bad 100644 --- a/www/.kktrc.ts +++ b/www/.kktrc.ts @@ -11,6 +11,11 @@ export default (conf: Configuration, env: 'production' | 'development', options: VERSION: JSON.stringify(pkg.version), }), ); + conf.ignoreWarnings = [ + { + module: /node_modules[\\/]parse5[\\/]/, + }, + ]; conf.module!.exprContextCritical = false; if (env === 'production') { conf.optimization = { diff --git a/www/package.json b/www/package.json index 66153e6b1..e0890237f 100644 --- a/www/package.json +++ b/www/package.json @@ -6,7 +6,7 @@ "author": "kenny wang ", "scripts": { "build": "kkt build", - "start": "GENERATE_SOURCEMAP=false kkt start", + "start": "kkt start", "map": "source-map-explorer build/static/js/*.js --html build/website-result.html" }, "license": "MIT",