Skip to main content

Website overview

emaw-website is the public Every Man A Warrior website: marketing pages, the book store, conference registration, giving, the resource library and optional user accounts. It replaces the legacy everymanawarrior.com site at launch.

Package nameemapw-website (sic)
StackReact 19, Vite 8, TypeScript 6, react-router-dom 7, Tailwind 4, react-i18next, Stripe (@stripe/react-stripe-js checkout), Sanity client
HostingCloudflare Pages project emaw-website
Dev URLhttps://develop-website.everymanawarrior.cc (Cloudflare Access)
BackendVITE_EMAW_API_BASE_URL → https://dev.emaw-app.com / https://app.emaw-app.com
Own docsCLAUDE.md (architecture and conventions), docs/ (sandbox runbooks, R2, go-live)
Testsnone configured; ESLint + Prettier

Layout​

src/
routes/index.tsx the pageRoutes array, mounted under / and /es
pages/ one file per route (+ account/, legal/)
components/
layout/ Navbar, Footer, Layout, LanguageSwitcher, LocaleProvider
store/ events/ donations/ account/ checkout/ marketing/ forms/
lib/
i18n/ i18next setup, URL-path detector, LocalizedLink, locales/{en,es}/<ns>.json
sanity/ client, queries, env
content/ static JSON content that used to be in Sanity (staff, books, store products)
store.ts events.ts donations.ts resources.ts auth.ts contact.ts app.ts backend API clients
cart/ CartProvider (localStorage)
account/ AuthProvider, useAuth, useAfterSignIn, google.ts
stripe.ts address.ts media/r2.ts
hooks/ useSanityQuery, useDraftMode, useAsync
types/ content.ts (hand-written), sanity.types.ts (generated in the Studio repo)
constants/ docs/ public/ repo-root, not inside src/

Path alias @/* → src/*.

What it does, in one table​

AreaPagesBackendNotes
MarketingHome, About, Pure Warrior, Books, Getting Started Right, News, Contactrest/contact/, rest/resources/Most copy is static JSON + i18n; News and Contact copy from Sanity
StoreStore, Product, Cart, Checkout, Success/Cancelrest/store/*Stripe Elements, server-side shipping
EventsConferences, Conference detailrest/events/*Registration then Stripe payment; past recaps from Sanity
GivingDonaterest/donations/*Staff gifts hand off to TWR; fund gifts in-house via Stripe
ResourcesResources, Resource detail, Getting Started Right videosrest/resources/*Media from R2 via backend URLs
AccountsSign in / up, forgot password, Account (history), Open apprest/api/token/*, rest/auth/*, rest/account/*Shared with the mobile and web apps; hand-off to the web app
LegalTerms, PrivacyEnglish only

Routes and pages in detail: Features. Routing, i18n and Sanity: Architecture.

Deployment at a glance​

Push to develop → GitHub Action → wrangler pages deploy → develop-website.everymanawarrior.cc. Production is a manual deploy today. See Deployment.