Loading...
Loading...
The ossido binary drives everything: scaffolding, development, and production
builds. Install it from npm (@ossido-labs/ossido-cli) or the ossido_cli crate -
see Installation. This page covers
each command.
ossido devStarts the development environment:
In one process, ossido dev:
.ossido/.Type derives into .ts
definitions your pages import.Leave it running while you work; it re-runs the relevant steps as files change:
.rs
route rebuilds and restarts the server; a deleted route stops being served after
a hard refresh..env file reloads it inside the running server, with no restart
(see Environment Variables).ossido buildProduces a production build:
By default it uses the output mode from ossido.config.ts. You can override
that mode per build, and control JavaScript emission:
--static (-s) - statically generate the site's HTML (SSG), overriding the
config.--server - build the standalone SSR server binary, overriding the config.--no-js-emit - skip emitting the client JavaScript bundle.--no-cargo - skip compiling the server binary (see below).--verbose (-v) - show the full output of Vite, cargo and the build hooks,
including cargo's progress bar.The two output modes produce different artifacts:
For server output, ossido build also runs cargo build --release and finishes by
reporting where the server binary is and how big it is. That release compile is
the slowest part of a build, so if something else already compiles the binary -
for example a CI job or a Dockerfile that runs its own cargo build --release -
pass --no-cargo to skip it:
The build prints a short checklist with a spinner per step: scaffolding, types, the app bundle, the server compile, and static generation. Once everything has finished, it prints the route tree and the emitted files.
prebuild and postbuild hook logs
appear dimmed and indented under the checklist. In CI, or whenever output is
piped, each step prints as a plain line instead of an animated spinner. Pass
--verbose to see everything Vite and cargo print.
ossido newScaffolds a new project. This is covered in detail in Installation & project setup; in short:
It supports flags for every wizard option (--template, --tailwind, --mdx,
--output, --alias, --head, --yes) so you can scaffold non-interactively.
--template starts from one of the
official examples, such as
kitchen-sink or with-websockets.
From a bare JS toolchain, npm create ossido@latest my-app wraps this same
command (see Installation).
ossido doctorRuns read-only diagnostics on your project and toolchain - Rust and Node/Bun versions, your installed CLI and package versions against the latest published, and common setup problems - then prints a pass / warn / fail report:
It changes nothing and exits non-zero only on a hard failure, so it's useful in CI or when something just won't build.
--offline - skip the network checks (the crates.io / npm latest-version
lookups).ossido upgradeBumps your project's ossido crate and @ossido-labs/* npm packages to a newer
version - keeping the two runtimes aligned - and refreshes the lockfiles. Run it
with no arguments for an interactive version picker:
--version <x.y.z> - upgrade to a specific version (defaults to the latest
published).--dry-run - report the planned change without touching any files.--yes (-y) - skip the confirmation prompt.--no-install - update the manifests but don't run cargo update or the
package-manager install..ossido/ directoryBoth ossido dev and ossido build write to a .ossido/ directory at the
project root. It contains generated code, including:
src/routes/, andYou don't edit anything in .ossido/ - it's regenerated from your source on
every run, and hand edits are overwritten. Treat it as build output (and it's
fine to keep it out of version control).
Back to Mental model & architecture · Installation & project setup