Fix init.sx: move out of component directory to avoid server-side eval
All checks were successful
Build and Deploy / build-and-deploy (push) Successful in 5m26s

init-client.sx contains browser-only code (dom-listen, collect! cssx).
It was in sx/sx/ which load_sx_dir scans and evaluates server-side,
causing "Undefined symbol: dom-listen". Move to sx/init-client.sx
which is outside the component load path.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
2026-03-14 11:57:40 +00:00
parent 7556cc303d
commit 48d493e9cc
2 changed files with 1 additions and 1 deletions

View File

@@ -71,7 +71,7 @@ def create_app() -> "Quart":
# sx docs uses custom highlight.py, not Prism; body.js is for legacy apps
# Load init SX from file — styles + nav behavior, no inline Python strings
import os as _os
_init_path = _os.path.join(_os.path.dirname(__file__), "sx", "init.sx")
_init_path = _os.path.join(_os.path.dirname(__file__), "sxc", "init-client.sx.txt")
with open(_init_path) as _f:
_init_sx = _f.read()
app.config["SX_SHELL"] = {