Overview
The ExisJS CLI (exis / exisjs) is a developer tool that assists in initializing, developing, building, and running ExisJS applications.
The CLI is engineered around ExisJS core conventions: file-system routing under src/http/, schema validation with tex, directory-scoped boundaries (boundary.ts), and high-performance production builds with route manifests.
Installation
The CLI can be run on-demand via npx or installed globally via npm:
# Run on-demand (recommended for scaffolding new projects)$ npx exisjs init my-api
# Or install globally$ npm install -g exisjsInside an initialized ExisJS project, the CLI is locally available and executed via npx exisjs or npm run <script>.
Basic Workflow
Once in your terminal, invoke CLI commands directly:
# View help for all commands$ npx exisjs --help
# View help for a specific command$ npx exisjs generate --helpTo create and run a new project:
$ npx exisjs init my-app$ cd my-app$ npm run devOpen http://localhost:4000 (or the dynamically resolved available port) to access your running API.
CLI Command Syntax
All ExisJS CLI commands follow this standard structure:
exisjs <command> [arguments] [options]For example:
# Scaffold a new route with functional syntax$ npx exisjs generate route users
# Scaffold with class-based (OOP) decorators$ npx exisjs generate route users --oop
# Use the short alias$ npx exisjs g r users --oopCommand Overview
| Command | Alias | Description |
|---|---|---|
dev | Starts the development server with HMR and automatic port collision avoidance. | |
build | Type-checks and compiles TypeScript to production JavaScript with route manifest generation. | |
start | Runs the compiled production server. | |
routes | Prints the application routing table to the terminal. | |
generate | g | Scaffolds framework slices (resource, route, service, schema, boundary, plugin, middleware, test). |
test | Runs the native Node.js test suite (node:test) with custom Jest-style reporting. | |
repl | console | Starts an interactive Node.js REPL loaded with the application context. |
exports | Displays all available @exisjs and exisjs/* subpath exports. | |
info | Displays system, Node.js, and ExisJS runtime information. | |
init | Initializes a new ExisJS application in the current directory. |