Commands
The CLI has two core commands shipped in @sigx/cli (create and info) plus a set of commands contributed by plugins at runtime. Run any command through your package runner:
pnpm dlx sigx <command>Core commands
sigx create
Scaffolds a new SignalX project by copying a bundled template into ./<name> and substituting the {{projectName}} placeholder.
sigx create [name] [--type <basic|ssr|ssg|lynx>] [--styling <none|tailwind|daisyui>] [--yes|-y]
By default it runs an interactive prompt-kit flow on @sigx/terminal: an intro, a name text prompt, then type and styling select prompts, a scaffolding spinner, and a "next steps" note. It falls back to headless, flag-driven mode when any of the following is true:
- standard output / input is not a TTY (for example, in CI or when piped),
--yes/-yis passed,- both
--typeand a positionalnameare provided.
Flags & arguments
| Argument | Values | Default | Description |
|---|---|---|---|
name (positional) | any directory name | my-sigx-app | Target directory created under the current folder. |
--type | basic, ssr, ssg, lynx | basic | Project template to copy. |
--styling | none, tailwind, daisyui | none | Styling preset. daisyui is also offered for lynx (maps to @sigx/lynx-daisyui). |
--yes / -y | — | — | Skip the prompts and run headlessly with defaults/flags. |
Examples
sigx create my-app --type basic
sigx create my-app --type ssr --styling tailwind
sigx create my-app --type ssg --styling daisyui
sigx create my-app --type lynx --styling tailwind
Interactive prompts:
pnpm dlx sigx createExit codes
1— target directory already exists, or the requested template was not found.2— invalid--typeor--stylingvalue.
Notes
- If the target directory is inside a pnpm workspace (a
pnpm-workspace.yamlis found by walking up the tree),@sigx/*dependencies in the generatedpackage.jsonare rewritten toworkspace:*. - Templates ship a
gitignorefile that is renamed to.gitignoreon copy (npm strips.gitignorefrom published tarballs). - Text files have their
{{projectName}}placeholders substituted on copy; binary assets (PNG icons in thelynxtemplate) are copied byte-for-byte. - The terminal prompt kit (
@sigx/terminal) is lazy-loaded, so it is only pulled in when you actually runcreateinteractively.
Templates & pinned versions
Templates pin a matched set of sigx / @sigx/* versions — never latest — so a freshly scaffolded project's peer graph resolves with a single copy of @sigx/reactivity under strict peer deps. The web templates (basic, ssr) pin the 0.6 core line; the ssg and lynx templates pin the matched set their plugin (@sigx/ssg / @sigx/lynx-cli) is built against. Third-party deps (vite, express, tailwindcss, …) keep their own caret ranges.
The SSR templates (ssr, ssr-tailwind, ssr-daisyui) scaffold a server built on the 0.6 document render API:
- an Express 5
server.js— Vite middleware in dev (ssrLoadModuleforentry-server), static client assets + the built server bundle in prod; - an
index.htmlwith the standard<!--ssr-outlet-->marker; - an
entry-server.tsxrender()that serves crawlers and AI agents a blockingrenderDocument(complete inline HTML, no client work) and everyone else a streamingrenderDocumentToNodeStream(theshellpromise settles before the first byte, so a failed render can still become a proper 500); - an
entry-client.tsxthat gates hydration on the server's completion signal (window.__SIGX_STREAMING_COMPLETE__/ thesigx:readyevent), emitted in both modes, so hydration always runs against finished server HTML.
npm run dev / start / preview run node server.js; build runs vite build plus a vite build --ssr of entry-server.
sigx info
Prints environment and project diagnostics. No flags.
sigx info
It reports:
- platform / architecture and Node.js version,
- the pnpm or npm version,
- the project
nameandversionfrompackage.json, - detected
@sigx/*dependencies (andsigx), - detected config files:
sigx.lynx.config.ts/js,lynx.config.ts/js,ssg.config.ts,vite.config.ts.
When a Lynx config is detected it additionally probes the Lynx toolchain: rspeedy version, ANDROID_HOME / ANDROID_SDK_ROOT, JDK version, ADB version and connected devices, and on macOS Xcode and CocoaPods.
Plugin-provided commands
The following commands are not part of @sigx/cli — they are discovered at runtime from installed plugin packages whose detect(cwd) returns true for your project. See Installation for which package provides each one, and Authoring Plugins to write your own.
sigx dev
Starts the dev server. Provided by @sigx/vite for web projects and @sigx/lynx-cli for Lynx.
sigx dev
sigx build
Runs a production build. Provided by @sigx/vite (web) and @sigx/lynx-cli (Lynx).
sigx build
sigx preview
Serves a built SSG site. Provided by @sigx/ssg.
sigx preview
sigx prebuild
Generates native iOS/Android project files. Provided by @sigx/lynx-cli.
sigx prebuild
sigx run:android
Builds and launches the app on an Android device or emulator. Provided by @sigx/lynx-cli.
sigx run:android
sigx run:ios
Builds and launches the app on iOS. Provided by @sigx/lynx-cli.
sigx run:ios
sigx doctor
Verifies the Lynx toolchain (rspeedy, ADB, Xcode, JDK). Provided by @sigx/lynx-cli.
sigx doctor
Command resolution & conflicts
The CLI builds its command list by starting with the core info and create commands, then registering each discovered plugin command. On a name collision the last plugin wins, and a warning is logged:
[sigx] WARN Plugin "X" overrides command "Y"
