Standalone home for the ExploringAI "data napkin math" content and website.
This repository is the source of truth for both the markdown content and the Astro site. You can edit, run, and build the project directly from this repo without using Extenote.
content/markdown inputs and scenarios used by the sitewebsite/Astro app that loads content from../contentat dev/build timehelpers/shared helper utilities and components
Prerequisite: a working node + npm installation.
From the repository root:
npm --prefix website install
npm --prefix website run devThe local dev server will start on http://localhost:4321.
To create a production build:
npm --prefix website run buildThe built site is written to website/dist/.
To preview the production build locally:
npm --prefix website run previewIf you prefer, you can also cd website and run the same npm commands there.
- Update
content/inputs/for input definitions. - Update
content/scenarios/for scenario pages and calculations. - Update
website/src/for site UI or rendering changes.
Because the Astro site reads directly from content/, changes made in this repo show up in local development and production builds without any separate sync step.
Contributions are welcome through GitHub issues and pull requests.
Open an issue for bugs, content corrections, feature ideas, or questions about calculations. Helpful issues usually include:
- a short summary of the problem or proposal
- links to the relevant page, scenario, or content file
- expected behavior and what you saw instead
- screenshots or examples when the change affects the site UI
For code or content changes:
- Create a branch from the latest default branch.
- Make your changes in
content/,website/, or both. - Run
npm --prefix website run buildto verify the site still builds. - Open a pull request with a clear summary of what changed and why.
If your PR addresses an existing issue, link it in the pull request description.
This repo now supports a split deployment flow:
gh-pagesis the pinned/stable GitHub Pages branch forhttps://exploringai.orgmaindeploys to a Cloudflare Pages dev site throughwrangler- pull requests targeting
mainalso get Cloudflare preview deployments when the PR branch lives in this repo
GitHub Pages stays stable until you explicitly promote a ref with the Promote GitHub Pages workflow in GitHub Actions.
- Open the workflow named
Promote GitHub Pages - Enter the ref you want to publish, such as
mainor a specific commit SHA - Run the workflow
The workflow builds website/dist/ and updates the existing gh-pages branch with that output.
In GitHub repository settings, keep Pages configured to deploy from the gh-pages branch at the repository root.
Cloudflare deploys are handled by the Deploy Cloudflare Pages workflow and use wrangler pages deploy.
Required GitHub secrets:
CLOUDFLARE_API_TOKENCLOUDFLARE_ACCOUNT_ID
Recommended GitHub repository variables:
CLOUDFLARE_PAGES_PROJECT_NAMEUse something likeexploringai-devCLOUDFLARE_DEV_SITE_URLUse the canonical dev URL for build metadata, such ashttps://dev.exploringai.org
One-time Cloudflare setup:
- Authenticate Wrangler locally if you want to run the setup commands yourself:
npm --prefix website exec wrangler login - Create a Pages project with
mainas the production branch:npm --prefix website exec wrangler pages project create exploringai-dev --production-branch main - Optionally attach a custom domain such as
dev.exploringai.org. - Keep the dev domain out of search indexing; this repo builds Cloudflare deploys with
noindex.
Once those secrets and variables are set, pushes to main and internal PRs to main will deploy automatically.