You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
fix: Resolve SSR fetch for components.json + update CLAUDE.md
- Use absolute URL (https://www.aitmpl.com) for server-side fetch of components.json
- Set site config in astro.config.mjs as fallback
- Update CLAUDE.md to reflect unified single Vercel project architecture
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
-`dashboard/src/lib/api/changelog-parser.ts` — Claude Code changelog parser
231
204
232
205
### Emergency Rollback
233
206
@@ -294,54 +267,70 @@ GA_SERVICE_ACCOUNT_JSON # Base64 service account (optional)
294
267
295
268
**Graceful degradation:** Each source catches its own errors. Missing secrets or API failures show `⚠️ Unavailable` instead of crashing the report.
296
269
297
-
## Dashboard (app.aitmpl.com)
270
+
## Dashboard (www.aitmpl.com)
298
271
299
-
Astro + React + Tailwind dashboard deployed at `https://app.aitmpl.com`. Clerk auth for user collections. Source lives in `dashboard/`.
272
+
Astro + React + Tailwind dashboard serving both `www.aitmpl.com` and `app.aitmpl.com`. Clerk auth for user collections. Source lives in `dashboard/`. All API endpoints are Astro API routes in the same project.
300
273
301
274
### Architecture
302
275
303
276
-**Framework**: Astro 5 with React islands, Tailwind v4, `output: 'server'`
304
277
-**Auth**: Clerk (`window.Clerk` global, no ClerkProvider per island)
305
-
-**Data**: Fetches from `https://www.aitmpl.com/components.json`at runtime (NOT bundled)
306
-
-**API proxy**: `dashboard/src/pages/api/[...path].ts` proxies to `localhost:3000` in dev, `https://www.aitmpl.com` in prod
278
+
-**Data**: `components.json` and `trending-data.json`served from `dashboard/public/` (same-origin)
279
+
-**APIs**: All endpoints in `dashboard/src/pages/api/` (Astro API routes, no separate serverless project)
307
280
308
281
### Vercel Project Setup
309
282
310
-
Two separate Vercel projects deploy from the same repo:
Each directory has its own `.vercel/project.json` with the correct project ID. Do NOT mix them up.
289
+
The legacy root project (`aitmpl`) is archived — only its `.vercel.app` subdomain remains.
318
290
319
291
### Deployment
320
292
321
293
**ALWAYS use the deployer agent (`.claude/agents/deployer.md`) for all deployments.** It runs pre-deploy checks (auth, git status, API tests) and handles the full pipeline safely. Never deploy manually.
322
294
323
295
```bash
324
-
npm run deploy:site # Deploy www.aitmpl.com (main site + API)
325
-
npm run deploy:dashboard # Deploy app.aitmpl.com (Astro dashboard)
326
-
npm run deploy:all # Deploy both
296
+
npm run deploy # Deploy www + app.aitmpl.com
297
+
npm run deploy:dashboard # Same as above
327
298
```
328
299
329
300
**CI/CD**: Pushes to `main` auto-deploy via GitHub Actions (`.github/workflows/deploy.yml`):
330
-
- Changes in `docs/`, `api/`, or `vercel.json` trigger site deploy
331
-
- Changes in `dashboard/` trigger dashboard deploy
0 commit comments