From 29f148a61381727a432c22a71c7a2b7cc23d9c9e Mon Sep 17 00:00:00 2001 From: Chocobozzz Date: Tue, 2 Feb 2021 15:33:58 +0100 Subject: Add ability to build client with source maps --- scripts/build/client.sh | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) (limited to 'scripts/build') diff --git a/scripts/build/client.sh b/scripts/build/client.sh index 0e7925be5..fd072b18c 100755 --- a/scripts/build/client.sh +++ b/scripts/build/client.sh @@ -43,7 +43,12 @@ rm -rf ./dist ./compiled # Don't build other languages if --light arg is provided if [ -z ${1+x} ] || ([ "$1" != "--light" ] && [ "$1" != "--analyze-bundle" ]); then - npm run ng build -- --prod --output-path "dist/build" + additionalParams="" + if [ ! -z ${1+x} ] && [ "$1" == "--source-map" ]; then + additionalParams="--sourceMap=true" + fi + + npm run ng build -- --prod --output-path "dist/build" $additionalParams for key in "${!languages[@]}"; do lang=${languages[$key]} -- cgit v1.2.3