This repository contains the MBX website, built as a Vite + React single-page app. Most page content lives in JSON files under content/, so routine site updates can usually be made without editing React components.
All editable page data lives in content/:
-
content/home.jsonsubheading: home page subtitle.info_title: heading for the home page information section.info: Markdown text. Use\n\nfor paragraph breaks.
-
content/publications.jsonitems: publication objects withtitle,authors,date,citation,link,description, andimg_src.- Publication images are stored in
public/publications/. - Set
img_srcto a filename such aspub202.png; set it to""to show no image.
-
content/faq.jsonitems: FAQ objects withquestionandanswer.- Answers are rendered as Markdown.
-
content/about.jsoncurrent: current contributors.former: former contributors.- Contributor images are stored in
public/people/. - Set
imageto a filename such asfpaesani.png; omit it or set it to""to show no photo.
-
content/updates.jsonupdates: release objects withversion,date,releaseNotes, andchangelog.- The updates pages, updates sidebar, and download page all read from this file.
- The download page defaults release notes and source ZIP links to the matching MBX GitHub release tag.
-
content/tutorials.jsonintroduction: main tutorials page content withheadingandmarkdown_text.tutorials: tutorial page objects withheading,markdown_text, and optionalpath.- If
pathis omitted, the route is generated from the lower-case heading with spaces replaced by hyphens.
Vite serves files in public/ from the site root.
- Site assets such as the logo live directly under
public/. - Contributor photos live under
public/people/. - Publication figures live under
public/publications/. - Do not include
public/in JSON image paths.
Examples:
{
"image": "fpaesani.png"
}{
"img_src": "pub202.png"
}Install dependencies:
npm installRun the development server:
npm run devOpen the local site:
http://localhost:5173
npm run dev: start the Vite development server.npm run build: type-check and build the production site intodist/.npm run serve: preview the production build locally.npm run lint: run the TypeScript type check.npm run format: format the repository with Prettier.npm run test: run Playwright tests.npm run test:e2e: run Playwright tests.npm run check-git-hooks: verify the secret-scan git hooks.
The build and lint scripts both run tsc --noEmit. Prettier is available through npm run format.
Playwright tests live under e2e/ and tests/e2e/. CI installs Playwright browsers before running the test suite.
The site builds as a Vite single-page app and can be deployed to any static host that serves dist/.
The GitHub Actions workflows currently:
- run type checks, build, and Playwright tests on pushes and pull requests to
mainormaster; - deploy the Vite build to GitHub Pages on pushes to
main; - copy
dist/index.htmltodist/404.htmlso browser-routed pages work on GitHub Pages.