Problem
We hold places for hundreds of cities, but there is only one indexable page for all of them. Someone searching for "SAT exam centre in Pune" finds nothing from us, even though the answer is sitting in data/places/sat_centre.json.
Where to start
data/places/*.json - one file per category, every record has a city field
data/places.schema.json - the record shape
- Build the route at
src/app/city/[slug]/page.tsx
What to build
A statically generated page per city, listing that city's places grouped by category.
Derive the slug from the existing city field. Please do not introduce a second city list or a separate slug mapping file; the dataset should stay the single source of truth.
Use generateStaticParams so the pages prerender at build time.
Put the city name in the <title>, the <h1> and the meta description. Link each place through to its map deep link (see #118).
Thin cities matter here. A city with two entries should still read as a real page, so include a short prompt to contribute more places for that city rather than leaving a near-empty page.
Acceptance criteria
Verifying
npm install
npm run build # confirm the city routes appear as prerendered
npm run dev
Scope: medium to large, roughly 4 hours.
New to the repo? Start with CONTRIBUTING.md.
Problem
We hold places for hundreds of cities, but there is only one indexable page for all of them. Someone searching for "SAT exam centre in Pune" finds nothing from us, even though the answer is sitting in
data/places/sat_centre.json.Where to start
data/places/*.json- one file per category, every record has acityfielddata/places.schema.json- the record shapesrc/app/city/[slug]/page.tsxWhat to build
A statically generated page per city, listing that city's places grouped by category.
Derive the slug from the existing
cityfield. Please do not introduce a second city list or a separate slug mapping file; the dataset should stay the single source of truth.Use
generateStaticParamsso the pages prerender at build time.Put the city name in the
<title>, the<h1>and the meta description. Link each place through to its map deep link (see #118).Thin cities matter here. A city with two entries should still read as a real page, so include a short prompt to contribute more places for that city rather than leaving a near-empty page.
Acceptance criteria
npm run validatestill passesVerifying
npm install npm run build # confirm the city routes appear as prerendered npm run devScope: medium to large, roughly 4 hours.
New to the repo? Start with CONTRIBUTING.md.