Skip to content

feat: add TanStack Intent skills and fix publishing#7161

Open
jherr wants to merge 1 commit intomainfrom
feat/intent-skills-audit
Open

feat: add TanStack Intent skills and fix publishing#7161
jherr wants to merge 1 commit intomainfrom
feat/intent-skills-audit

Conversation

@jherr
Copy link
Copy Markdown
Contributor

@jherr jherr commented Apr 12, 2026

Summary

  • Fix @tanstack/react-router skill publishing: The package had skills/ on disk and bin/intent.js but was missing "skills" in the files array, @tanstack/intent as a devDependency, and the bin entry in package.json. The 3 react-router skills (Query composition, React Router migration guide) were silently not being published to npm.
  • Add tanstack-intent keyword to all 11 skill-bearing packages for npm-based skill discovery (matching the pattern used by @tanstack/ai).
  • Create standalone route-masking skill: Extracted from the not-found-and-errors skill into its own SKILL.md under router-core/skills/router-core/route-masking/, covering mask on Link/navigate, createRouteMask, unmaskOnReload, and sharing behavior.
  • Add TanStack Query composition skills for @tanstack/solid-router and @tanstack/vue-router (adapted from the existing @tanstack/react-router composition skill with framework-appropriate APIs).
  • Complete _artifacts/skill_tree.yaml: Expanded from 13 entries (router-core + react-router only) to 31+ entries covering all Start, framework, plugin, and new skills.

Test plan

  • Verify npm pack for @tanstack/react-router includes the skills/ directory
  • Verify tanstack-intent keyword appears in all 11 package.json files
  • Verify _artifacts/skill_tree.yaml parses as valid YAML
  • Spot-check new SKILL.md files for correct frontmatter and cross-references

Made with Cursor

Summary by CodeRabbit

  • New Features

    • Route masking now has dedicated, comprehensive documentation with usage patterns
    • Added integration guides for TanStack Query with Solid Router and Vue Router
  • Documentation

    • Reorganized route masking content into its own skill section for improved clarity
    • Enhanced framework support documentation for Vue router tooling

- Fix @tanstack/react-router to publish skills (add skills to files
  array, @tanstack/intent devDep, bin entry)
- Add tanstack-intent keyword to all 11 skill-bearing packages for
  npm discoverability
- Create standalone route-masking skill (extracted from
  not-found-and-errors)
- Add TanStack Query composition skills for solid-router and
  vue-router
- Update _artifacts/skill_tree.yaml with all Start, framework,
  plugin, and new skills

Made-with: Cursor
@coderabbitai
Copy link
Copy Markdown
Contributor

coderabbitai bot commented Apr 12, 2026

📝 Walkthrough

Walkthrough

This PR adds TanStack Intent support metadata and skill documentation across 11 packages. It introduces npm discoverability improvements via tanstack-intent keywords, extracts route-masking into a dedicated skill documentation, adds TanStack Query composition guidance for Solid and Vue routers, and updates the skill tree artifact to reflect new framework bindings and Start framework capabilities.

Changes

Cohort / File(s) Summary
Package Keyword Additions
packages/react-start/package.json, packages/router-core/package.json, packages/router-plugin/package.json, packages/solid-router/package.json, packages/solid-start/package.json, packages/start-client-core/package.json, packages/start-server-core/package.json, packages/virtual-file-routes/package.json, packages/vue-router/package.json, packages/vue-start/package.json
Added "tanstack-intent" keyword to package metadata across 10 packages for npm discoverability.
React Router Configuration
packages/react-router/package.json
Added "tanstack-intent" keyword, expanded files whitelist to include skills and bin, introduced @tanstack/intent as devDependency, and added CLI bin entry mapping intent to ./bin/intent.js.
Route Masking Skill Extraction
packages/router-core/skills/router-core/not-found-and-errors/SKILL.md, packages/router-core/skills/router-core/route-masking/SKILL.md, packages/router-core/skills/router-core/SKILL.md
Extracted route-masking content from not-found-and-errors skill into dedicated documentation; added routing decision tree reference.
Query Composition Skills
packages/solid-router/skills/compositions/router-query/SKILL.md, packages/solid-router/skills/solid-router/SKILL.md, packages/vue-router/skills/compositions/router-query/SKILL.md, packages/vue-router/skills/vue-router/SKILL.md
Added TanStack Query integration documentation for Solid and Vue routers covering loader patterns, QueryClient setup, and common mistakes; updated parent skill index with cross-references.
Artifact & Changeset Metadata
_artifacts/skill_tree.yaml, .changeset/intent-skills-audit.md
Updated skill tree with router v1.168.15 metadata, added new framework bindings (solid-router, vue-router), TanStack Start skills hierarchy, and standalone route-masking skill; added coordinating changeset for patch releases.

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~12 minutes

Poem

🐰 With skills now sorted and intent in sight,
We've masked those routes and queried right,
From Solid to Vue, the frameworks align,
New docs shine bright in TanStack's design!
Hop along now, the metadata's prime! ✨

🚥 Pre-merge checks | ✅ 3
✅ Passed checks (3 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title accurately summarizes the main changes: adding TanStack Intent skills to packages and fixing publishing configuration for react-router.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch feat/intent-skills-audit

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 and usage tips.

@nx-cloud
Copy link
Copy Markdown
Contributor

nx-cloud bot commented Apr 12, 2026

View your CI Pipeline Execution ↗ for commit 359b89e


☁️ Nx Cloud last updated this comment at 2026-04-12 00:23:40 UTC

Copy link
Copy Markdown
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

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

Actionable comments posted: 3

🧹 Nitpick comments (2)
_artifacts/skill_tree.yaml (2)

425-509: Wire start-server-core into the server-side Start skills.

start-server-core is added here as a standalone core, but none of the server-oriented Start skills depend on it. That leaves the new node disconnected from the graph and can surface server-functions, middleware, server-routes, or deployment without the server runtime prerequisite.

Suggested diff
   - name: 'Server Functions'
     slug: 'start-core/server-functions'
@@
     requires:
       - 'start-core'
+      - 'start-server-core'
@@
   - name: 'Start Middleware'
     slug: 'start-core/middleware'
@@
     requires:
       - 'start-core'
+      - 'start-server-core'
       - 'start-core/server-functions'
@@
   - name: 'Server Routes'
     slug: 'start-core/server-routes'
@@
     requires:
       - 'start-core'
+      - 'start-server-core'
@@
   - name: 'Deployment'
     slug: 'start-core/deployment'
@@
     requires:
       - 'start-core'
+      - 'start-server-core'

Also applies to: 511-525

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@_artifacts/skill_tree.yaml` around lines 425 - 509, The new core node
start-server-core was added but not wired into server-related skills; update the
requires arrays for the server-focused sub-skills (references:
'start-core/server-functions', 'start-core/middleware',
'start-core/server-routes', 'start-core/deployment' and any other
server-oriented entries around the same section) to include 'start-server-core'
so those nodes depend on the server runtime; ensure you add 'start-server-core'
to each requires list consistently (and mirror the same change for the repeated
block noted in the comment).

528-594: Add the framework-router prerequisites to the Start framework nodes.

These entries are framework-specific wrappers on top of the corresponding router bindings, but their requires only include start-core. Adding the matching router skill keeps the learning graph ordered correctly and avoids presenting react-start/solid-start/vue-start as standalone from react-router/solid-router/vue-router.

Suggested diff
   - name: 'React Start'
     slug: 'react-start'
@@
     requires:
       - 'start-core'
+      - 'react-router'
@@
   - name: 'Solid Start'
     slug: 'solid-start'
@@
     requires:
       - 'start-core'
+      - 'solid-router'
@@
   - name: 'Vue Start'
     slug: 'vue-start'
@@
     requires:
       - 'start-core'
+      - 'vue-router'
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@_artifacts/skill_tree.yaml` around lines 528 - 594, Update the framework
skill nodes so their requires include the matching router skill: for the 'React
Start' node (slug 'react-start') add 'react-router' to the requires array; for
'Solid Start' (slug 'solid-start') add 'solid-router'; and for 'Vue Start' (slug
'vue-start') add 'vue-router' so each framework wrapper depends on its
corresponding router skill in addition to 'start-core'.
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.

Inline comments:
In `@packages/react-router/package.json`:
- Line 109: The package.json change adds a new devDependency "@tanstack/intent"
but the pnpm lockfile wasn’t updated, causing CI failure; run pnpm install (or
pnpm install --lockfile-only) to regenerate pnpm-lock.yaml so it includes the
new specifier, verify the lockfile is updated, and commit the updated
pnpm-lock.yaml alongside the package.json change before pushing.

In `@packages/solid-router/skills/compositions/router-query/SKILL.md`:
- Around line 26-28: The MD028 markdown lint error is caused by an empty blank
line inside the blockquote around the CRITICAL notes; remove the blank line so
the two CRITICAL lines are contiguous in the same blockquote. Edit the SKILL.md
block that mentions defaultPreloadStaleTime and the SSR QueryClient guidance
(references: defaultPreloadStaleTime, createRouter, QueryClient, TanStack Query,
Router) and ensure there are no blank lines between the blockquote lines so the
blockquote is properly formatted.

In `@packages/vue-router/skills/compositions/router-query/SKILL.md`:
- Around line 26-28: Remove the extra blank line inside the blockquote in
SKILL.md so the two CRITICAL notes become contiguous blockquote lines;
specifically, merge the two lines containing "**CRITICAL**: Set
`defaultPreloadStaleTime: 0`..." and "**CRITICAL**: For SSR, create
`QueryClient`..." by deleting the empty line between them so markdownlint MD028
no longer flags the blockquote formatting.

---

Nitpick comments:
In `@_artifacts/skill_tree.yaml`:
- Around line 425-509: The new core node start-server-core was added but not
wired into server-related skills; update the requires arrays for the
server-focused sub-skills (references: 'start-core/server-functions',
'start-core/middleware', 'start-core/server-routes', 'start-core/deployment' and
any other server-oriented entries around the same section) to include
'start-server-core' so those nodes depend on the server runtime; ensure you add
'start-server-core' to each requires list consistently (and mirror the same
change for the repeated block noted in the comment).
- Around line 528-594: Update the framework skill nodes so their requires
include the matching router skill: for the 'React Start' node (slug
'react-start') add 'react-router' to the requires array; for 'Solid Start' (slug
'solid-start') add 'solid-router'; and for 'Vue Start' (slug 'vue-start') add
'vue-router' so each framework wrapper depends on its corresponding router skill
in addition to 'start-core'.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro

Run ID: 9a110b09-27a1-411e-9f5c-fbca860db843

📥 Commits

Reviewing files that changed from the base of the PR and between 55201ad and 359b89e.

📒 Files selected for processing (20)
  • .changeset/intent-skills-audit.md
  • _artifacts/skill_tree.yaml
  • packages/react-router/package.json
  • packages/react-start/package.json
  • packages/router-core/package.json
  • packages/router-core/skills/router-core/SKILL.md
  • packages/router-core/skills/router-core/not-found-and-errors/SKILL.md
  • packages/router-core/skills/router-core/route-masking/SKILL.md
  • packages/router-plugin/package.json
  • packages/solid-router/package.json
  • packages/solid-router/skills/compositions/router-query/SKILL.md
  • packages/solid-router/skills/solid-router/SKILL.md
  • packages/solid-start/package.json
  • packages/start-client-core/package.json
  • packages/start-server-core/package.json
  • packages/virtual-file-routes/package.json
  • packages/vue-router/package.json
  • packages/vue-router/skills/compositions/router-query/SKILL.md
  • packages/vue-router/skills/vue-router/SKILL.md
  • packages/vue-start/package.json

"isbot": "^5.1.22"
},
"devDependencies": {
"@tanstack/intent": "^0.0.14",
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

⚠️ Potential issue | 🟠 Major

CI blocker: lockfile is out of sync with new devDependency.
Line 109 adds @tanstack/intent, but pipeline logs show pnpm install --frozen-lockfile fails because pnpm-lock.yaml was not updated. Please regenerate and commit the lockfile with this specifier.

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@packages/react-router/package.json` at line 109, The package.json change adds
a new devDependency "@tanstack/intent" but the pnpm lockfile wasn’t updated,
causing CI failure; run pnpm install (or pnpm install --lockfile-only) to
regenerate pnpm-lock.yaml so it includes the new specifier, verify the lockfile
is updated, and commit the updated pnpm-lock.yaml alongside the package.json
change before pushing.

Comment on lines +26 to +28
> **CRITICAL**: Set `defaultPreloadStaleTime: 0` when using TanStack Query. Without this, Router's built-in preload cache (30s default) prevents Query from controlling data freshness.

> **CRITICAL**: For SSR, create `QueryClient` inside the `createRouter` factory function. A module-level singleton leaks data between server requests.
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

⚠️ Potential issue | 🟡 Minor

Fix markdownlint MD028 blockquote formatting.
Line 27 introduces a blank line between blockquote lines, which triggers no-blanks-blockquote.

Suggested fix
 > **CRITICAL**: Set `defaultPreloadStaleTime: 0` when using TanStack Query. Without this, Router's built-in preload cache (30s default) prevents Query from controlling data freshness.
-
 > **CRITICAL**: For SSR, create `QueryClient` inside the `createRouter` factory function. A module-level singleton leaks data between server requests.
📝 Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
> **CRITICAL**: Set `defaultPreloadStaleTime: 0` when using TanStack Query. Without this, Router's built-in preload cache (30s default) prevents Query from controlling data freshness.
> **CRITICAL**: For SSR, create `QueryClient` inside the `createRouter` factory function. A module-level singleton leaks data between server requests.
> **CRITICAL**: Set `defaultPreloadStaleTime: 0` when using TanStack Query. Without this, Router's built-in preload cache (30s default) prevents Query from controlling data freshness.
> **CRITICAL**: For SSR, create `QueryClient` inside the `createRouter` factory function. A module-level singleton leaks data between server requests.
🧰 Tools
🪛 markdownlint-cli2 (0.22.0)

[warning] 27-27: Blank line inside blockquote

(MD028, no-blanks-blockquote)

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@packages/solid-router/skills/compositions/router-query/SKILL.md` around lines
26 - 28, The MD028 markdown lint error is caused by an empty blank line inside
the blockquote around the CRITICAL notes; remove the blank line so the two
CRITICAL lines are contiguous in the same blockquote. Edit the SKILL.md block
that mentions defaultPreloadStaleTime and the SSR QueryClient guidance
(references: defaultPreloadStaleTime, createRouter, QueryClient, TanStack Query,
Router) and ensure there are no blank lines between the blockquote lines so the
blockquote is properly formatted.

Comment on lines +26 to +28
> **CRITICAL**: Set `defaultPreloadStaleTime: 0` when using TanStack Query. Without this, Router's built-in preload cache (30s default) prevents Query from controlling data freshness.

> **CRITICAL**: For SSR, create `QueryClient` inside the `createRouter` factory function. A module-level singleton leaks data between server requests.
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

⚠️ Potential issue | 🟡 Minor

Fix markdownlint MD028 blockquote formatting.
Line 27 has a blank line between blockquoted CRITICAL notes, which causes the linter warning.

Suggested fix
 > **CRITICAL**: Set `defaultPreloadStaleTime: 0` when using TanStack Query. Without this, Router's built-in preload cache (30s default) prevents Query from controlling data freshness.
-
 > **CRITICAL**: For SSR, create `QueryClient` inside the `createRouter` factory function. A module-level singleton leaks data between server requests.
📝 Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
> **CRITICAL**: Set `defaultPreloadStaleTime: 0` when using TanStack Query. Without this, Router's built-in preload cache (30s default) prevents Query from controlling data freshness.
> **CRITICAL**: For SSR, create `QueryClient` inside the `createRouter` factory function. A module-level singleton leaks data between server requests.
> **CRITICAL**: Set `defaultPreloadStaleTime: 0` when using TanStack Query. Without this, Router's built-in preload cache (30s default) prevents Query from controlling data freshness.
> **CRITICAL**: For SSR, create `QueryClient` inside the `createRouter` factory function. A module-level singleton leaks data between server requests.
🧰 Tools
🪛 markdownlint-cli2 (0.22.0)

[warning] 27-27: Blank line inside blockquote

(MD028, no-blanks-blockquote)

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@packages/vue-router/skills/compositions/router-query/SKILL.md` around lines
26 - 28, Remove the extra blank line inside the blockquote in SKILL.md so the
two CRITICAL notes become contiguous blockquote lines; specifically, merge the
two lines containing "**CRITICAL**: Set `defaultPreloadStaleTime: 0`..." and
"**CRITICAL**: For SSR, create `QueryClient`..." by deleting the empty line
between them so markdownlint MD028 no longer flags the blockquote formatting.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant