HOSTING FOR AI-BUILT APPS
Deploy a static JavaScript regex playground on Yeeted
The cold-start canary: zero dependencies, no build step, bare
index.html + one ES module - the platform's simplest static path. If this
sample deploys slowly, the platform is slow; nothing else can be blamed.
Logic lives in src/matcher.js (pure, DOM-free) so node --test
test/matcher.test.js covers it - including the XSS-escape property and
zero-width-pattern termination. smoke.sh <url> checks a deployment.
Run locally
From static/regex-vanilla, use Node.js for the pure logic tests and Python
for a local static server:
node --test test/matcher.test.js
python3 -m http.server 8000
Open http://localhost:8000; serving over HTTP allows the browser to load
the JavaScript module. Try cat against cat catalog and inspect the
highlighted matches. Invalid patterns display an error.
Deploy and verify
Follow the deployment walkthrough. Upload this
folder's index.html and src/matcher.js together. No database, package
installation, Dockerfile, or build command is required.
sh smoke.sh "$PREVIEW_URL"
The deployed smoke script checks the static resources. The Node tests cover matching, flag normalization, escaped output, and stopping on a zero-width match. Open the page to verify the full browser interaction separately.
What to change before real use
Matching runs on the browser's main thread. A pathological regular expression can block the tab; there is no worker timeout or complexity limit. Zero-width matches stop the loop rather than being counted like ordinary matches. These are deliberate limits of the small demo, not a complete regex workbench.