No results
2
Setup
Ella Mizuki edited this page 2026-07-03 04:33:23 +00:00
Setup
Prerequisites
- Node.js 24.x (see
.nvmrc) - pnpm 11.8.0 (see
package.json#packageManager) - Git
Quick Start
# Clone the repository
git clone https://github.com/isyuricunha/beta-website.git
cd beta-website
# Install dependencies
pnpm install
# Start the development server
pnpm dev
# → http://localhost:4321
Available Commands
| Command | Description |
|---|---|
pnpm dev |
Start Astro dev server with HMR |
pnpm build |
Type-check + production static build |
pnpm preview |
Serve dist/ locally for verification |
pnpm check |
Run astro check + content validation |
pnpm lint |
Type-check only (astro check) |
pnpm test |
Run Node test runner suites |
pnpm content:new:post |
Scaffold a new blog post (all 6 locales) |
pnpm content:new:snippet |
Scaffold a new snippet (all 6 locales) |
pnpm content:translate |
Generate missing translations via adapter |
pnpm content:check |
Validate content structure, frontmatter, cross-locale consistency |
pnpm migrate:legacy-content |
One-time legacy → collections migration |
First Build Verification
Run the full local validation to ensure everything is set up correctly:
pnpm check
pnpm test
pnpm build
The build output goes to the dist/ directory, ready for static hosting.
Development Workflow
- Content changes — Edit MDX in
src/content/, auto-reload works. - UI copy changes — Edit
src/i18n/locales/{locale}.ts, hot-reload works. - Component changes — Edit
.astro/.tsfiles, HMR works. - Style changes — Edit
global.cssor component<style>, HMR works.
Environment Variables
| Variable | Purpose | Required |
|---|---|---|
CONTENT_TRANSLATION_COMMAND |
CLI for auto-translation | No (for content:translate) |
CONTENT_TRANSLATION_ARGS |
JSON args array for above | No |
STRICT_I18N |
Set to true to enforce strict translation validation |
No |
IDE Setup (VS Code)
Recommended extensions:
- Astro (official)
- Tailwind CSS IntelliSense
- TypeScript (built-in)
Common Issues
| Issue | Fix |
|---|---|
node: not found |
Run nvm use or use Node 24.x |
pnpm: command not found |
corepack enable && corepack prepare [email protected] --activate |
| Build fails on types | Run pnpm check to see full diagnostics |
| Content not showing | Check draft: false, publishedDate in past, locale matches filename |
| Translation fallback not working | Verify getLocalizedListing() logic in src/lib/content.ts |