Skip to main content

Prerequisites

Install the tooling below before cloning the repo or running npm run setup. Meridian’s Meridian/package.json declares engines.node: 20.x—use Node 20, not 18 or 22, unless you intentionally align the whole team on a different major. You will also need Git (for clone and normal development). npm ships with Node.

Node.js 20.x and npm

Pick one approach:Option A — Homebrew
Option B — nvm (recommended if you switch Node versions often)
Option C — Official installerDownload the 20.x LTS macOS installer from https://nodejs.org/ and run it.Verify:

MongoDB Community Server

Meridian’s backend expects a MongoDB instance you can reach from Meridian/backend/.env (for example mongodb://127.0.0.1:27017/...). The steps below install MongoDB Community Server locally—not Atlas.
Install (Homebrew — MongoDB tap)
Start the databaseRun mongod in the foreground when debugging, or register a background service:
Check it is listening
To stop the background service later: brew services stop mongodb-community.
Homebrew’s formula name and data directory can change over time; if brew install mongodb-community fails, run brew search mongodb and follow the current MongoDB Server install on macOS docs.

GitHub CLI (gh)

The Meridian CLI uses gh for pull requests and merges when you run flows like meridian ship. Install it even if you use another Git UI day to day.
Follow the prompts (HTTPS or SSH, GitHub.com, login via browser). Confirm with gh auth status.

Verify installs

Clone Meridian

Clone the Meridian Git repository (the web + API app)—not a parent “monorepo” meta-repo. You only need Meridian/ on disk to start; other repos are added next to it with npm run setup / meridian setup or manually.
Use the clone URL from GitHub for Meridian if yours differs (fork, HTTPS, enterprise host).
“Meridian-Mono” in conversation or older notes usually means a suggested local folder layout: one parent directory whose children include Meridian/, Events-Backend/, and optionally Meridian-Mobile/. That parent folder is not a single git repository you clone—it’s just the recommended development repo structure.
From here on, Meridian/ means the root of the Meridian repo you cloned (where package.json with meridian / dev scripts lives).

Bootstrap with the Meridian CLI

From Meridian/, the recommended first step is:
That runs meridian setup, which installs dependencies, can clone Events-Backend if it is missing, and can link backend/events to the sibling Events-Backend checkout (see platform tabs below). If the meridian command is already on your PATH, you can run meridian setup instead of npm run setup.

Platform-specific setup

Put meridian on your PATH

From Meridian/:
After that, meridian should resolve in any terminal. If it does not, confirm your global npm bin is on PATH (often npm prefix -g plus /bin).

Events-Backend and backend/events

Layout should be:
After npm run setup, accept the prompt to symlink, or run:
Node creates a normal symlink here; no extra Windows-style steps.

MongoDB

If you installed MongoDB Community in Prerequisites, ensure it is running:

Free a port (3000 / 5001)

Health check

Workspace layout

Meridian and Events-Backend should be sibling directories under whatever parent folder you use (again: the parent is not a repo—only Meridian and Events-Backend are separate clones):
Optional: add Meridian-Mobile/ as another sibling if you work on the Expo app; it is its own clone, not inside Meridian.

Environment variables

Create both:
  • Meridian/.env
  • Meridian/backend/.env
At minimum:
Use MONGODB_URI when the backend is configured to read that variable instead of MONGO_URI_RPI.

Run the app

From Meridian/:
  • Frontend: http://localhost:3000
  • Backend: http://localhost:5001

Run services separately

Backend (preserves backend/events links):
Frontend only:

Verify

  1. Open http://localhost:3000
  2. Hit the backend health endpoint (see macOS vs Windows tabs above for curl vs PowerShell).

Development workflow

  • Frontend hot-reloads via the webpack dev server
  • Backend runs under nodemon when using npm run dev
From Meridian/:
See Testing for suites, folders, and CI.

Development

Day-to-day workflow, debugging, and troubleshooting after the stack is up.

Web client best practices

React conventions, routing, state, and useFetch / postRequest API access.

Backend best practices

req.db, routes, auth middleware, and multi-tenant patterns in Meridian/backend.

Authentication overview

Login methods, JWT cookies vs mobile tokens, and links to SAML and sessions.

Multi-tenant identity

Global users, memberships, and SSO across school subdomains.

SAML

University IdP integration when a tenant enables institutional SSO.

Testing

npm run test:*, folder layout, and CI parity.

API reference

REST surfaces and how the web and mobile clients call them.

Troubleshooting

From Meridian/:
Need more detail on the CLI? See Meridian CLI. For general workflow help, see the Development guide.