Skip to content

serve

Serve the generated static site locally.

Terminal window
./ritual serve [options]
OptionDescriptionDefault
-p, --port <number>Port to serve on3000

Serve on default port (3000):

Terminal window
./ritual serve

Serve on a custom port:

Terminal window
./ritual serve --port 8080
  1. Build the site:
Terminal window
./ritual build-site
  1. Serve it:
Terminal window
./ritual serve
  1. Open http://localhost:3000 in your browser
  • The serve command serves files from the dist/ directory
  • Make sure to run build-site first to generate the content
  • Press Ctrl+C to stop the server
  • To build and serve in one step, use serve-site instead