Skip to content

docs: extract cross-app patterns into skill v1.9 and AGENTS.md#1

Merged
carlosvin merged 3 commits into
mainfrom
docs/skill-v1.9-cross-app-patterns
Apr 22, 2026
Merged

docs: extract cross-app patterns into skill v1.9 and AGENTS.md#1
carlosvin merged 3 commits into
mainfrom
docs/skill-v1.9-cross-app-patterns

Conversation

@carlosvin
Copy link
Copy Markdown
Owner

@carlosvin carlosvin commented Apr 19, 2026

Summary

Bumps the tanstack-fullstack-pattern skill to v1.9.0 by extracting generic, non-business-specific patterns observed across three downstream apps and adds the operational detail to AGENTS.md.

  • Ports rules 26–29 back into the YAML source. They had drifted into the generated SKILL.md only, so the build artifact was ahead of the canonical source. This restores pnpm skills:build as the single path of truth.
  • Adds 7 new rigid rules (30–36) — patterns that appeared in 2+ apps and are genuinely architectural.
  • Extends AGENTS.md with inline amendments (Tier 4) and 5 new top-level sections (Tier 3) covering the larger code patterns.

New rigid rules in the skill (30–36)

# Rule Origin
30 Public runtime config bridge via getPublicEnv() + window.__ENV__ inline <script> all 3 apps
31 Router UX defaults bundle (stale time, preload, scroll restoration, notFoundComponent) all 3 apps
32 Project-local Link wrapper that preserves search by default 2 apps
33 Public-route allowlist in authMiddleware with synthetic anonymous AuthContext 2 apps
34 Sentry.setUser + feedbackIntegration({ autoInject: false }) header button 2 apps
35 Single docs/help.md backs /help, an AI tool, and the chat's suggested prompts 2 apps
36 getDistinctValues(field) method → server function → read-only AI tool for every enum-ish field 2 apps

New AGENTS.md sections (13–17)

  • §13 Public Runtime Config — full template: server function, HTML-safe <script> injection, declare global for window.__ENV__.
  • §14 Bulk Edit Pattern — URL-driven multi-select, category tabs, dirty tracking, bulkWrite batch mutations, "Apply all" row.
  • §15 Override / Overlay Repository Pattern — source collection + sparse overrides + pure applyOverrides(), \$set/\$unset semantics, "Revert to source".
  • §16 Sortable Tables (Controlled Mode) — uncontrolled vs controlled modes, pure sortRows(), null-sinking.
  • §17 Autosave Forms with Concurrency GuardshasMounted guard for spurious mount PATCH, isPatching ref for concurrent PATCH collision prevention.

Inline AGENTS.md amendments (Tier 4)

  • §3 — hydration-safe useComputedColorScheme + useIsMounted
  • §4 — satisfies over as, in-operator narrowing for unknown errors
  • §5 — public-route allowlist body + pre-auth 308 redirect middleware pattern
  • §7 — loaderDeps cache keying, functional-form navigate, child routes reading parent loader data
  • §8 — virtual-field explanation registry, fluent system-prompt builder
  • §10 — Zod round-trip test factories, dual Playwright webServer with in-process HTTP mock

Test plan

  • pnpm skills:build regenerates SKILL.md, skills/dist/…, and skills/registry.json
  • pnpm format — clean
  • pnpm lint — Biome + tsc --noEmit + skills:check all green
  • Spot-check the regenerated SKILL.md rendering in an agent session to confirm rules 30–36 surface when expected

Made with Cursor

Ports rules 26-29 back into the canonical YAML source (they had drifted
into the generated SKILL.md only) and adds rules 30-36 capturing generic
patterns observed across multiple downstream apps: public env bridge,
router UX defaults, Link wrapper preserving search, public-route
allowlist, Sentry user+feedback binding, single markdown artifact for
help/AI/prompts, and distinct-value filter discovery tools.

AGENTS.md gains inline amendments (hydration-safe color scheme, satisfies
over as, pre-auth redirect middleware, loaderDeps cache keying,
virtual-field explainer, fluent prompt builder, Zod round-trip factories,
dual Playwright webServer) and new top-level sections for Public Runtime
Config, Bulk Edit Pattern, Override/Overlay Repository Pattern, Sortable
Tables, and Autosave Forms with concurrency guards.

Made-with: Cursor
Comment thread .agents/skills/tanstack-fullstack-pattern/SKILL.md Outdated
Comment thread .agents/skills/tanstack-fullstack-pattern/SKILL.md Outdated
Comment thread .agents/skills/tanstack-fullstack-pattern/SKILL.md Outdated
Comment thread AGENTS.md Outdated
Comment thread AGENTS.md Outdated
Comment thread AGENTS.md Outdated
Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Updates the tanstack-fullstack-pattern skill to v1.9.0 by bringing the YAML source back in sync with generated artifacts, adding new cross-app architectural rules, and expanding AGENTS.md with operational patterns that support those rules.

Changes:

  • Bump tanstack-fullstack-pattern to v1.9.0 and port rules 26–29 back into the YAML source of truth.
  • Add new rigid rules (30–36) and propagate them into the generated registry/dist/agent-skill outputs.
  • Extend AGENTS.md with new sections (Public Runtime Config, Bulk Edit, Overrides overlay, Sortable tables, Autosave concurrency guards) and inline amendments.

Reviewed changes

Copilot reviewed 4 out of 5 changed files in this pull request and generated 1 comment.

Show a summary per file
File Description
skills/src/tanstack-fullstack-pattern.skill.yaml Canonical skill source updated (v1.9.0, rules 26–36, refreshed capabilities/constraints/steps).
skills/registry.json Generated registry updated to reflect new version and metadata.
skills/dist/tanstack-fullstack-pattern.md Generated public markdown updated (v1.9.0 + new rules text).
AGENTS.md Adds new operational guidance sections/amendments; renumbers “Validate Changes” section.
.agents/skills/tanstack-fullstack-pattern/SKILL.md Generated agent-consumable skill updated with rules 26–36.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread AGENTS.md Outdated
@carlosvin carlosvin merged commit c680ea8 into main Apr 22, 2026
1 check passed
@carlosvin carlosvin deleted the docs/skill-v1.9-cross-app-patterns branch April 22, 2026 08:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants