generate
The generate group scaffolds code into an existing workspace: frontend
components and hooks, service classes, test suites, documentation, backend
services, and complete full-stack features.
re-shell generate --help| Subcommand | Purpose |
|---|---|
component <name> |
Generate a new component. |
hook <name> |
Generate a React hook. |
service <name> |
Generate a service class. |
test <workspace> |
Generate a test suite for a workspace. |
docs |
Generate project documentation. |
backend <name> |
Generate a backend service or API. |
feature <name> (alias create-feature) |
Create a full-stack feature (CRUD, auth, file-upload, websocket, graphql). |
generate backend
Section titled “generate backend”Usage: re-shell generate backend [options] <name>
Options: --framework <framework> express, fastapi, django, flask, sanic, tornado, laravel, symfony, slim, codeigniter (default: "express") --language <language> typescript, python, php (default: "typescript") --features <features...> code-quality, celery, redis, type-hints, hot-reload, pytest --workspace <workspace> Target workspace --port <port> Default port for the service (default: "8000") --verbose Show detailed informationre-shell generate backend billing --framework express --language typescriptre-shell generate backend orders --framework fastapi --language python --features redis pytestPreview the file set first with
templates apply <id>.
generate feature
Section titled “generate feature”Creates a full-stack feature wired across the backend and frontend in one step.
Usage: re-shell generate feature [options] <name>
Options: --type <type> crud, auth, file-upload, websocket, graphql, fullstack (default: "crud") --backend <framework> express, fastify, nestjs, etc. --frontend <framework> react, vue, svelte, angular, vanilla (default: "react") --language <language> typescript, javascript, python, go, rust (default: "typescript") --database <database> prisma, typeorm, mongoose, sequelize, none (default: "none") --openapi Include an OpenAPI specification --graphql Use GraphQL instead of REST --websockets Include WebSocket support --skip-install Skip package installationre-shell generate feature invoices --type crud --backend express --frontend react --database prismare-shell generate feature chat --type websocket --frontend vue --language typescriptgenerate component / hook / service
Section titled “generate component / hook / service”re-shell generate component UserCardre-shell generate hook useDebouncere-shell generate service PaymentGatewaygenerate test / docs
Section titled “generate test / docs”re-shell generate test storefrontre-shell generate docscreate and related commands
Section titled “create and related commands”The top-level create, add, and init commands scaffold at the project and
microfrontend level. create is non-interactive for every mode: every prompt has
a default that is used with --yes, --json or --dry-run, or when stdin is not a
terminal, so it never waits for input. A condition that needs a human decision (an
incompatible stack, an existing target) fails with a non-zero exit; pass --force to
proceed.
# A bare create is a react-ts frontend app at apps/webre-shell create web
# Backend only, frontend only, full stackre-shell create api --backend expressre-shell create web --frontend react-tsre-shell create shop --fullstack --db prisma
# Microfrontend (Module Federation): a shell plus remotesre-shell create hub --microfrontend --remotes cart,search:vue
# Polyglot microservices with a gatewayre-shell create platform --polyglot --gateway traefik --services users:fastapi,orders:express
# An empty workspace skeletonre-shell create ws --template blank
# Add a microfrontend to an existing projectre-shell add checkout --route /checkout --port 5174| Flag | Purpose |
|---|---|
--template <id> |
A backend template id, a frontend framework, an architecture template, or blank. An unknown id is TEMPLATE_NOT_FOUND. |
--frontend / --framework / --backend / --db |
Pick the stacks (templates list shows the ids). |
--fullstack / --microfrontend / --polyglot |
Project modes. |
--gateway <fw> / --services <list> |
Polyglot gateway (express, fastify, nestjs, traefik, kong) and name:framework,... services. |
--remotes <list> |
Microfrontend remotes as name[:framework],.... |
--type <type> |
Workspace type for a monorepo package: only app, package, lib or tool. |
--force |
Overwrite files in an existing target and continue past compatibility warnings. |
-y, --yes |
Use defaults and skip prompts (automatic when stdin is not a terminal). |
--dry-run / --verbose / --json |
Preview; --dry-run --json emits the exact file set. |
Workspaces created by create use the globs apps/*, packages/*, libs/*, tools/* and services/*, and
service is a workspace type alongside app, package, lib and tool.
create --dry-run --json returns the exact file set as a contract envelope, with
per-file sizes, added/modified/unchanged status, previews and diffs, and writes
nothing; the human preview goes to stderr. It is the same dry-run discipline as
templates apply.
re-shell create api --backend express --dry-run --json | jq '.data.summary'Skeletons versus runnable apps. create scaffolds real templates (38 files for
--backend express), while generate backend writes a smaller starter (for Express
only package.json, tsconfig.json and src/index.ts). Whether a given template’s
generated project installs, builds and boots is a separate question, answered by
template verification.
See also
Section titled “See also”- templates — discover what to scaffold.
- Template Catalog — all 204 templates.
- service & bridge — connect polyglot services.