docs: commit generated route and env declarations#34

open1
main
docs/commit-generated-dts
openedSep 24, 2026byAAviddaram
View on GitHubTwo-way sync enabledPR last imported 20d ago

Summary

  • AGENTS.md told agents to leave apps/web/file-routes.d.ts and apps/web/solid-env.d.ts unstaged. The committed copies drifted behind local regenerations, which blocked fast-forwarding the main checkout today.
  • The rule now says to commit them with the route or plugin change that regenerates them. CI's vp check and fresh worktrees typecheck against the committed copies, so they can't be gitignored.

Test plan

  • Doc-only change; pre-commit vp check --fix passed

Checks

4 successful · 1 skipped
All checks passed
d8d95aa

Added 1 commit

  • docs: commit generated route and env declarationsd8d95aa
Synced from GitHub

Important

  • 🔍 Trigger review

This repository does not receive automatic reviews because it has fewer than 10 stars.

⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Advanced

Run ID: 9596401b-f3e8-4184-b496-eb3cab17f440


Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

Synced from GitHub

RetriggerConfidence Score: 4/5

The PR appears safe to merge, though the declaration guidance should also cover env schema changes.

Findings

  1. P2 Env schema changes omitted ▶

Summary

The PR updates the agent guide to require committing generated web declarations alongside changes that regenerate them.

  • Removes the instruction to leave those declarations unstaged.
  • Adds a rationale based on checking committed copies in CI and fresh worktrees.

Reviews (1) · Last reviewed commit: "docs: commit generated route and env dec..."

AGENTS.mdline 27Open thread
……@@ -23,7 +23,8 @@ Make the smallest direct change. Use inferred types and named exports. New abstr
2525- The API Worker's resources and bindings live in `apps/api` (`resources.ts`, `index.ts`); `infra/alchemy.run.ts` composes the stack. Each resource has one definition.
26-- Deploy only from the main checkout, after build and plan review. Leave generated `apps/web/file-routes.d.ts` and `apps/web/solid-env.d.ts` unstaged.
26+- Deploy only from the main checkout, after build and plan review.
27+- Commit `apps/web/file-routes.d.ts` and `apps/web/solid-env.d.ts` with the route or plugin change that regenerates them. CI and fresh worktrees typecheck against the committed copies before any dev or build run writes them.

P2 Env schema changes omitted

solid-env.d.ts is regenerated from apps/web/env.ts, but this instruction mentions only route or plugin changes. An agent changing the env schema could therefore leave the committed declaration stale, causing a fresh-worktree typecheck to reject a new binding. Include env schema changes in the commit guidance.

suggestion
1- Commit `apps/web/file-routes.d.ts` and `apps/web/solid-env.d.ts` with the route, env schema, or plugin change that regenerates them. CI and fresh worktrees typecheck against the committed copies before any dev or build run writes them.