Help us improve
Share bugs, ideas, or general feedback.
From astro-builder
Scaffold a new page in the Astro 6 project. Creates the page file(s), a matching page-view, wires i18n, and registers the route for all configured locales. Arguments: page name and optional path (e.g. "about" or "blog/archive").
npx claudepluginhub pcamarajr/content-stack --plugin astro-builderHow this skill is triggered — by the user, by Claude, or both
Slash command
/astro-builder:new-pageThe summary Claude sees in its skill listing — used to decide when to auto-load this skill
You are scaffolding a new page in this Astro 6 project. The argument is the page name or path (e.g. `about`, `blog/archive`, `tags/[tag]`).
Use when implementing internationalization in Astro, configuring i18n routing, setting up locale strategies, using getRelativeLocaleUrl/getAbsoluteLocaleUrl, handling Astro.currentLocale, or adding hreflang tags with sitemap.
Comprehensive best practices, routing patterns, component architecture, and static site generation techniques for building high-performance Astro websites.
Builds content-focused websites with Astro's zero-JS islands architecture, multi-framework components (React/Vue/Svelte), and Markdown/MDX support. Triggers on .astro files, Astro.props, content collections.
Share bugs, ideas, or general feedback.
You are scaffolding a new page in this Astro 6 project. The argument is the page name or path (e.g. about, blog/archive, tags/[tag]).
Before writing any code:
CLAUDE.md and .astro-builder/content-schema.md to understand the project.astro.config.ts to get the i18n config (locales, default locale, routing).src/i18n/en.json (or the default locale file) to understand the translation key format.src/pages/ to understand the thin-wrapper pattern.src/page-views/ to understand the page-view pattern.Based on the argument $ARGUMENTS, determine:
[tag], [...slug]).Announce the plan: list the files you will create and the i18n keys you will add.
For each configured locale, create src/pages/{locale}/{path}.astro:
---
import {PageViewName} from "@page-views/{PageViewName}.astro";
---
<PageViewName />
That is all. No imports of data, no props, no logic. The page is a thin wrapper.
Create src/page-views/{PageViewName}.astro:
---
import { createTranslator } from "@lib/i18n";
import BaseLayout from "@layouts/BaseLayout.astro";
const tl = createTranslator(Astro.currentLocale);
const locale = Astro.currentLocale ?? "en";
// Data fetching goes here if needed
---
<BaseLayout title={tl("pageName.title")} description={tl("pageName.description")}>
<!-- Page markup here -->
</BaseLayout>
For each locale JSON file in src/i18n/, add the required translation keys:
{pageName}.title — page title{pageName}.description — meta descriptionIf the route has a dynamic segment (e.g. [tag]), add getStaticPaths() to the page-view, not the page file.
Run pnpm build. If there are TypeScript or build errors, fix them before finishing.
Report what was created:
/en/about, /it/chi-siamo).astro files — always use tl('key').Astro.url to detect locale — always use Astro.currentLocale.getStaticPaths to handle locales in a single page).CLAUDE.md (@/*, @components/*, etc.).