diff --git a/web/build.sh b/web/build.sh index 26583fe..8460f8b 100755 --- a/web/build.sh +++ b/web/build.sh @@ -8,7 +8,7 @@ LICENSE='/* @licstart The following is the entire license notice for the JavaScript code in this page. -Copyright (c) 2025 Xe Iaso +Copyright (c) 2025 Xe Iaso Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal @@ -36,9 +36,9 @@ for the JavaScript code in this page. mkdir -p static/locales cp ../lib/localization/locales/*.json static/locales/ -esbuild js/main.mjs --sourcemap --bundle --minify --outfile=static/js/main.mjs "--banner:js=${LICENSE}" -gzip -f -k -n static/js/main.mjs -zstd -f -k --ultra -22 static/js/main.mjs -brotli -fZk static/js/main.mjs - -esbuild js/bench.mjs --sourcemap --bundle --minify --outfile=static/js/bench.mjs +for file in js/*.mjs js/worker/*.mjs; do + esbuild "${file}" --sourcemap --bundle --minify --outfile=static/"${file}" --banner:js="${LICENSE}" + gzip -f -k -n static/${file} + zstd -f -k --ultra -22 static/${file} + brotli -fZk static/${file} +done