--- name: astro-page description: Migrate one hand-written HTML page of the ai-for-dummies site to an Astro route without changing its URL, content, or JS budget. Use for any page-level migration task. --- # Migrating a page to Astro ## Snapshot first, migrate second The snapshot is the only objective evidence that no content was lost. ```bash npm run serve & # vanilla site on :4173 node .agents/scripts/snapshot-route.mjs http://localhost:4173/models/ \ > .agents/snapshots/models.txt ``` Screenshot the same route at 560 / 800 / 1100 / 1600 px as well. ## Migrate ```bash cp .agents/templates/pages/chapter.astro src/pages/models.astro ``` Then, in order: 1. Move markup into the layout + components. Reuse existing components before creating new ones. 2. Move copy into `src/content/`. Both `en` and `pt`, copied literally — never retyped. 3. Move page CSS into component `