Beyond The Vibe, home

BlogContext

A real CLAUDE.md, line by line

The 123-line instructions file from this website's own repository, what each part is for, the commit that added it, and what isn't in it.

Florian van der Galiën

Most advice about CLAUDE.md is a list of things you could put in one. This post is about a single real file instead: the one in the repository behind this website, as it stood on 20 November 2026. It’s 123 lines long, and every part of it arrived in a commit, so I can tell you when each section was added and what prompted it.

A note on the name first. The file is called AGENTS.md, and CLAUDE.md is a symlink pointing to it. That’s been the case since the repository’s first commit on 18 July 2026. Codex and most other agents read AGENTS.md, Claude Code read CLAUDE.md, and the symlink gave them all the same text. Recent versions of Claude Code can also read AGENTS.md directly. With the symlink in place, Claude Code still finds a CLAUDE.md and reads that, which is the same file, so nothing needs to change.

Where the first 22 lines came from

I didn’t write these. When you create a new Astro project, create astro writes this AGENTS.md for you unless you pass --no-ai:

## Development

When starting the dev server, use background mode:

```
astro dev --background
```

Manage the background server with `astro dev stop`, `astro dev status`, and `astro dev logs`.

## Documentation

Full documentation: https://docs.astro.build

Consult these guides before working on related tasks:

- [Adding pages, dynamic routes, or middleware](https://docs.astro.build/en/guides/routing/)
- [Working with Astro components](https://docs.astro.build/en/basics/astro-components/)
- [Using React, Vue, Svelte, or other framework components](https://docs.astro.build/en/guides/framework-components/)
- [Adding or managing content](https://docs.astro.build/en/guides/content-collections/)
- [Adding styles or using Tailwind](https://docs.astro.build/en/guides/styling/)
- [Supporting multiple languages](https://docs.astro.build/en/guides/internationalization/)

The documentation half is still there, unchanged. The dev-server half lasted until 11 November, although the reasoning behind it holds: a development server runs until someone stops it, so an agent that starts one in the foreground sits waiting on a command that never finishes. In the background it keeps running while the agent carries on, and Astro records it in a lock file so a second agent doesn’t start a duplicate.

That works for one checkout. With a second copy of the repository in a git worktree, the two servers compete for port 4321, and the confirmation link in a waitlist mail can point at the wrong one. So the server now runs through portless, which gives every checkout its own address, and the section starts like this:

## Development

Start the dev server with `bun run dev` as a background command (your tool's background mode, not `astro dev --background`). It runs in the foreground through [portless](https://portless.sh) and serves `https://beyond-the-vibe.localhost`, or `https://<branch>.beyond-the-vibe.localhost` in a git worktree. Stop it by ending that command; `astro dev stop`, `status` and `logs` do not see this server. [...]

The parenthesis is aimed at what this file used to say. An agent that has worked on Astro projects knows astro dev --background, and here that command would start a server portless has no route for. The sentence about stop, status and logs is there for the same reason.

The rest of the section describes my machine. A TLS proxy sits in front of portless, and my shell sets three environment variables for it that an agent’s shell never loads. Nothing in the repository shows that, so the file gives the full command with the variables written out.

The documentation links matter because an agent’s knowledge of a framework is only as recent as its training. When an agent added the blog you’re reading, the content collections guide in that list was the first stop, because that part of Astro’s API has changed between major versions.

After editing code

This is the section that does the most work. It went in on 19 July, in the same commit that added the type checker, the linter and the formatter, and step 4 followed later that day with fallow:

## After editing code

Run these in order after any code change. Do not report work as done until check and
lint are clean.

1. `bun run check` — `astro check`, type-checks `.astro` files and TS.
2. `bun run lint` — `oxlint`, type-aware linting is on by default via `.oxlintrc.json`.
   `bun run lint:fix` applies autofixes.
3. Once both pass, format **only the files you changed**:

   ```
   bunx prettier --write <file> [<file> ...]
   ```

   Do not run `bun run format` (whole-repo write) unless explicitly asked — it creates
   unrelated diff noise.

4. `bun run fallow:audit` — `fallow audit`, reviews only the changed files for dead
   code, duplication, complexity, and styling drift. Advisory: it reports but does not
   gate. Use `bun run fallow` for a full-codebase pass when doing broader cleanup.

If I could keep only one sentence from the whole file, it would be “Do not report work as done until check and lint are clean.” It tells the agent what “done” means in this repository. Without it, the agent decides that for itself.

The rest is about order and scope. The two checks that can fail come first and the formatter runs only once they pass. Formatting is limited to the files the agent touched, so a one-line fix doesn’t arrive wrapped in reformatting of files nobody meant to change.

Writing the post-edit checks into this file is a habit across my projects. In an analysis of my own Claude Code sessions from June to October 2026, a format, lint and type-check chain written into CLAUDE.md turned up in 5 to 15 sessions. Why each rung is there, and how long each takes, is in How do you know AI-written code works?.

Editing Astro templates

### Editing Astro templates

Prettier wraps long markup, and Astro's minifier collapses newline+indent between
inline elements to **nothing** (a literal single space survives). Splitting two
adjacent inline elements across lines therefore silently deletes the space between
them. Where a space is meaningful, write it explicitly as `{' '}` — see the submit label
and spinner in `WaitlistSection.astro`. After reformatting markup, confirm the built HTML
is unchanged rather than trusting the source diff.

This one describes a trap the agent can’t see. Nothing in the source looks wrong, the diff looks like harmless reformatting, and a space between two words disappears from the page. An agent has no way to spot it unless the file warns it.

The section also shows that the file needs maintenance. When it was written, the example it pointed to was a small terminal in the curriculum section of the landing page. On 27 July that terminal was removed, and the same commit moved the pointer to the waitlist button. Left alone, the instruction would have sent the agent looking for an example that no longer existed.

Lint configuration

### Lint configuration

`max-lines` is off for `src/data/**/*.ts` (see `overrides` in `.oxlintrc.json`, which
being JSON cannot say why). Those files are flat content — the curriculum, the landing
copy — where length counts lessons, not branches, and the rule fired every time a module
gained sessions. It stays on everywhere else.

This went in on 8 September, when the course modules roughly doubled, to twelve, ten and ten lessons, and the line-count rule started firing on the file that lists them. The linter’s config file is JSON, so the exception can’t carry a comment explaining itself. The reason has to live somewhere, and this file is where the agent will read it before it “fixes” the exception away.

The paragraph is slightly wrong, though. The override doesn’t switch max-lines off for those files. It raises the limit to 1,000 lines, which is also what the commit message that added it says. Nothing checks prose against config, and that’s the main weakness of keeping reasons in a file like this.

A second paragraph, added on 13 October, does the same for the brand/ folder, which holds the templates for social media images and is excluded from both the linter and fallow.

TypeScript version constraint

### TypeScript version constraint

`typescript` is pinned to **6.x** on purpose. `astro check` relies on the programmatic
compiler API that TypeScript's native compiler (7.0+) does not yet expose, so upgrading
to 7.x breaks `bun run check`. oxlint's type-aware rules work fine on 6.x. Track
https://github.com/withastro/roadmap/discussions/1321 before bumping.

A pinned version without a reason looks like neglect, and an agent asked to update dependencies is likely to update it. My usual dependency prompt, which appears in 5 to 15 sessions in the analysis, tells the agent to update everything except a pinned major version that’s known to be incompatible. In this repository, this section is how an agent finds out which one, and the link tells it what to check before that changes.

Fallow configuration

### Fallow configuration

`.fallowrc.json` is deliberately near-empty — fallow's astro plugin already detects the
right entry points, so zero config is the intended state. Two things to know:

- Do not add the `entry` globs that `fallow recommend` proposes. It reports
  `frameworks_present: []` and falls back to a generic `src/index|main` convention that
  matches nothing here. `fallow list` shows the real, plugin-detected entry points.
- `tailwindcss` is in `ignoreDependencies`. This is a static build, so Tailwind is
  compiled into `dist/` and never ships; without the entry it is reported as a dev
  dependency used in production on every run.

Commit-blocking git/agent hooks (`fallow hooks install`) are available but intentionally
not installed.

The first bullet tells the agent to ignore a tool’s own advice. fallow suggests a configuration change that would do nothing useful here, and an agent asked to tidy the setup could easily accept it. The bullet is there to stop that.

Since then, .fallowrc.json has gained more ignored dependencies, and none of them made it into this file. That config format allows comments, so each reason sits next to its entry, where the agent reads it when it opens the config.

The part a tool wrote

Lines 17 to 44 aren’t mine either. They went in on 19 July, and the marker comments around them show they come from fallow’s setup step:

<!-- fallow:setup-hooks:start -->

## Fallow local gate

Before any `git commit` or `git push`, run `fallow audit --format json --quiet --explain --gate-marker agent`. If the verdict is `fail`, fix the reported findings before retrying. Treat JSON runtime errors like `{ "error": true, ... }` as non-blocking.

Audit defaults to `gate=new-only`: only findings introduced by the current changeset affect the verdict. [...]

## Fallow task map

| When the agent is about to...                                     | Run                                                                                  |
| ----------------------------------------------------------------- | ------------------------------------------------------------------------------------ |
| delete an "unused" export or file                                 | `fallow dead-code --trace <file>:<export>`                                           |
| delete an "unused" dependency                                     | `fallow dead-code --trace-dependency <name>`                                         |
| commit or open a PR                                               | `fallow audit --base <ref>`                                                          |
| prioritize refactoring                                            | `fallow health --hotspots --targets`                                                 |
| ask who owns code                                                 | `fallow health --ownership`                                                          |
| check untested-but-reachable code                                 | `fallow health --coverage-gaps`                                                      |
| consolidate duplication                                           | `fallow dupes --trace dup:<fingerprint>`                                             |
| find feature flags                                                | `fallow flags`                                                                       |
| check which architecture rules apply to a file before changing it | `fallow guard <files>`                                                               |
| surface security candidates                                       | `fallow security`                                                                    |
| understand a finding                                              | `fallow explain <issue-type>`                                                        |
| scope a monorepo                                                  | `--workspace <glob> / --changed-workspaces <ref>` (global flags, prefix any command) |

<!-- fallow:setup-hooks:end -->

The task map is useful. Before an agent deletes something that looks unused, it traces whether it really is, a step that’s easy to skip in the middle of a clean-up.

The block has caused two problems, though. fallow inserted it straight under the first heading, ## Development, so for almost four months the scaffold’s dev-server lines sat below it, under ## Fallow task map, where they didn’t belong. The portless change on 11 November fixed that in passing, because the new dev-server text went in above the block. The second problem is still there: the block contradicts the hand-written part. It says to run the audit before every commit and fix whatever fails. Step 4 further down calls the same audit “advisory”, and the fallow section says the commit-blocking hooks are “intentionally not installed”.

Both are instructions, so whether the gate holds depends on the agent following them. Anthropic’s documentation is plain about that: Claude treats these files “as context, not enforced configuration”, and if something must be blocked regardless, the tool for it is a hook.

What isn’t in it

There’s no paragraph on what Beyond The Vibe is and no map of the folders. The site is a landing page, its legal pages, the waitlist API and now this blog, and the agent can list the folders itself.

There are no style rules either. Prettier and oxlint enforce formatting and code conventions, and a rule a tool already enforces doesn’t need to be written out in prose.

Most of the reasoning behind individual decisions isn’t in this file. It sits in comments next to the code it explains. The list of testimonials in src/data/landing.ts, for example, is empty, and the comment above it starts:

/** Empty until real participants give real quotes. This held five invented quotes
 * attached to hot-linked Unsplash portraits of real, unrelated people. Fabricated
 * endorsements are a per-se unlawful commercial practice under Nr. 23c of the Anhang
 * zu § 3 Abs. 3 UWG [...]

An agent reads that at the moment it’s about to add a testimonial, which is the only moment it needs it. In AGENTS.md it would be loaded into every session, including the ones about CSS.

How it stays short

Anthropic’s guidance is to keep each CLAUDE.md under 200 lines, because longer files take up more context and get followed less reliably. This one is at 123, and 28 of those are fallow’s block.

Looking back through the history, most hand-written sections arrived in the same commit as the change they describe: the checks and the TypeScript pin with the tooling, the lint note with the lint override, the brand/ note with the brand folder, the corrected example with the deleted terminal, the new dev-server section with the switch to portless. The same preference shows up in my logs: “keep AGENTS.md minimal, but include after-edit instructions”. And when a file grows anyway, the prompt I’ve used is “CLAUDE.md is too convoluted, is there a skill to simplify it?”.

If you’re starting from a prototype rather than an existing codebase, Your Lovable, Bolt or v0 prototype works. What now? covers what to put in your first version of this file.