Bridge Minified Version

This commit is contained in:
Hassan DRAGA 2024-07-08 17:01:16 -04:00
parent faa02ad708
commit 2a79c2b526
4 changed files with 1347 additions and 2193 deletions

View File

@ -37,7 +37,7 @@ IF NOT EXIST "%project_root%\bridge\node_modules\esbuild\" (
REM Transpile WebUI-Bridge (TS to JS) & Convert WebUI-Bridge (JS to C) REM Transpile WebUI-Bridge (TS to JS) & Convert WebUI-Bridge (JS to C)
echo Transpile and bundle WebUI-Bridge from TypeScript to JavaScript... echo Transpile and bundle WebUI-Bridge from TypeScript to JavaScript...
.\node_modules\.bin\esbuild --bundle --target="chrome90,firefox90,safari15" --format=esm --tree-shaking=false --outdir=. ./webui_bridge.ts & %python_cmd% js2c.py .\node_modules\.bin\esbuild --bundle --target="chrome90,firefox90,safari15" --format=esm --tree-shaking=false --minify-syntax --minify-whitespace --outdir=. ./webui_bridge.ts & %python_cmd% js2c.py
echo Done. echo Done.
cd %cd% cd %cd%

View File

@ -59,7 +59,7 @@ if (-not (Test-Path "$project_root\bridge\node_modules\esbuild")) {
# Transpile WebUI-Bridge (TS to JS) # Transpile WebUI-Bridge (TS to JS)
if (!$silent) { Write-Host "Transpile and bundle WebUI-Bridge from TypeScript to JavaScript..." } if (!$silent) { Write-Host "Transpile and bundle WebUI-Bridge from TypeScript to JavaScript..." }
.\node_modules\.bin\esbuild --bundle --target="chrome90,firefox90,safari15" --format=esm --tree-shaking=false --outdir=. ./webui_bridge.ts $log_level .\node_modules\.bin\esbuild --bundle --target="chrome90,firefox90,safari15" --format=esm --tree-shaking=false --minify-syntax --minify-whitespace --outdir=. ./webui_bridge.ts $log_level
# Convert WebUI-Bridge (JS to C) # Convert WebUI-Bridge (JS to C)
if (!$silent) { Write-Host "Convert WebUI-Bridge JavaScript to C Header..." } if (!$silent) { Write-Host "Convert WebUI-Bridge JavaScript to C Header..." }

View File

@ -28,7 +28,7 @@ done
if [ "$silent" = true ]; then log_level=--log-level=warning; fi if [ "$silent" = true ]; then log_level=--log-level=warning; fi
if [ "$silent" != true ]; then echo "Transpile and bundle TS sources to webui.js"; fi if [ "$silent" != true ]; then echo "Transpile and bundle TS sources to webui.js"; fi
esbuild --bundle --target="chrome90,firefox90,safari15" --format=esm --tree-shaking=false --outdir=. ./webui_bridge.ts $log_level esbuild --bundle --target="chrome90,firefox90,safari15" --format=esm --tree-shaking=false --minify-syntax --minify-whitespace --outdir=. ./webui_bridge.ts $log_level
if [ "$silent" != true ]; then echo "Convert JS source to C header"; fi if [ "$silent" != true ]; then echo "Convert JS source to C header"; fi
python3 js2c.py python3 js2c.py

File diff suppressed because it is too large Load Diff