wasm

command
v0.0.0-...-b92b712 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Aug 18, 2026 License: MIT Imports: 9 Imported by: 0

Documentation

Rendered for js/wasm

Overview

Command gsx-wasm is the client-side playground engine. It runs the gsx transform (gsx -> Go) and the gsx formatter entirely in the browser — no go list, no subprocess — exposing two JS functions:

gsxTransform(source) -> {files: [{name, code}], diagnostics}
gsxFormat(source)    -> {formatted} | {error}

Rendering the generated Go to HTML is NOT done here (a browser has no Go compiler, and an interpreter can't handle component composition); the site posts the generated files to the playground server's /run instead.

Build: GOOS=js GOARCH=wasm go build -o gsx.wasm ./playground/wasm

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL