School Website
The public website for the Naalya schools — server-rendered React, editorial content from Sanity, application data from the REST API.
This is the public-facing website for the Naalya schools — the site a prospective parent lands on, reads about the campuses, browses the blog, and fills in an application. It is one project with one job: present the school well, and make it easy to take the next step.
Under the hood it is a server-rendered React app. Two very different kinds of data feed it, and keeping them straight is the single most useful mental model you can carry into this section. Editorial content — pages, blog posts, site settings, the words and images an editor controls — comes from a Sanity CMS. Application data — everything that lives in the school's own systems — comes from the Naalya Schools REST API through a fully type-safe, generated client. Sanity is what the marketing team edits; the API is what the school runs on.
New to the codebase? Start with Getting Started to get it running locally, then read How It's Built for the full architecture — the data-flow diagram, the two-application layout, and the key facts you'll reach for constantly all live there.
One repo, two applications
The source folder holds two independent apps: the website frontend at the repository root, and the Sanity Studio nested in sanity/ with its own dependencies. They deploy separately and the Studio is not part of the pnpm workspace — so you install and run it from inside its own folder. How It's Built explains why, and Sanity Setup walks the details.
Where to go next
This section runs from setup, through the frontend, into the CMS. You can start anywhere, but if you're unsure, these are the doors most people walk through first.
How It's Built
The architecture in one page: the two apps, how content and API data flow into the UI, and the key facts.
Getting Started
Toolchain, env vars, the global chowbea-axios CLI, and running the site locally.
The Stack
Every major library and the role it plays — framework, styling, data, and tooling.
Building the frontend
Project Structure
How the app/ folder is laid out and the conventions worth following.
Routing & Pages
Config-based routes, the loader and meta contract, and typed navigation.
Adding a Page
A step-by-step recipe for wiring up a new route end to end.
Styling & Theming
Tailwind v4 configured in CSS, theming, and the cn() helper.
Components
The shadcn/ui + Radix component layer and how to compose it.
The API Client
The generated, type-safe axios client that talks to the Naalya Schools API.
Forms
How forms are built, validated, and submitted to the backend.
The content layer
Sanity CMS
An overview of the content layer: the Studio, the frontend client, and visual editing.
Setup
Why the Studio is a separate project, plus its config, plugins, and env vars.
The Content Model
How content types are structured as a page of references.
Querying with GROQ
The query-module convention: typed queries, loaders, and hydration.
Single Documents & Singletons
Fetching one document — posts by slug, and the singleton pattern.
Images & Portable Text
Rendering Sanity images and rich text on the page.