Skip to content

Deployment

The docs app is a static Astro Starlight site located in docs/.

Terminal window
cd docs
npm install
npm run dev

The docs app uses Node.js >=22.12.0. This requirement applies only to the docs site build tooling. The ResourcesJS package itself still supports Node.js >=18.18.0.

Terminal window
cd docs
npm run build

The generated static site is written to:

docs/dist/

This repository includes a GitHub Actions workflow that builds and deploys the docs site from main.

To use resourcesjs.amrachraf.cloud with GitHub Pages:

  1. In GitHub, set Pages source to GitHub Actions.
  2. Point the DNS record for resourcesjs.amrachraf.cloud to GitHub Pages.
  3. Keep docs/public/CNAME set to resourcesjs.amrachraf.cloud.

Cloudflare Pages is also a good fit.

Recommended settings:

SettingValue
Root directorydocs
Build commandnpm run build
Build output directorydist
Node version22.12.0 or newer

Then connect the custom domain resourcesjs.amrachraf.cloud in the Cloudflare Pages dashboard.