Repository navigation
docs(vue): Add DataClientPlugin API page - #4143
Conversation
Vue-only page covering the managers, initialState, Controller and gcPolicy options, the $dataClient global property, and why awaited composables need <script setup>. Listed in the Vue API sidebar and linked from pages that mention DataClientPlugin. Also exports GCPolicy from @data-client/vue (as @data-client/react does) and points the missing-plugin error message at the new page. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01LHNQGac8kwCPEnyPLRYfZu
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
🦋 Changeset detectedLatest commit: 68b2107 The changes in this PR will be included in the next version bump. This PR includes changesets to release 1 package
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
|
Size Change: 0 B Total Size: 103 kB ℹ️ View Unchanged
|
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## master #4143 +/- ##
=======================================
Coverage 98.06% 98.06%
=======================================
Files 163 163
Lines 3095 3099 +4
Branches 616 616
=======================================
+ Hits 3035 3039 +4
Misses 18 18
Partials 42 42 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
Moves the State interface and GCPolicy options into shared partials used by both DataProvider and DataClientPlugin, documents DataProvider's gcPolicy prop, and links the Vue page to getDefaultManagers() instead of repeating the default manager lists. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01LHNQGac8kwCPEnyPLRYfZu
ntucker
left a comment
There was a problem hiding this comment.
Reviewed e16d39d091a633e32775d38c0c34763840e3bfaf. No actionable correctness findings. Checked the documented options, plugin start/stop and $dataClient behavior against their implementations, and checked the GCPolicy re-export and shared examples against the public types. The documented immortal Vue default matches this head. Validation: source/doc/changed-link review; I did not rebuild the website or run the Vue suite locally.
|
Sol review bot (GPT-6.1 Sol, High): I posted this review of commit |
Lists the new DataClientPlugin page in the data-client-vue and data-client-setup references.json and regenerates skill references (yarn build:skills) for this PR's doc changes. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01LHNQGac8kwCPEnyPLRYfZu
|
The website Generated by Claude Code |
|
Staff engineer (Cursor agent): CHANGE_THIS_PR (small) on f00e098.
Fix: add One leftover, fine as a follow-up if it isn't trivial: even after that fix, the setup copy's |
Marks DataClientPlugin.vue.md `frameworks: [vue]` so skills that list both frameworks render it for Vue (with /vue/ links) instead of React, and tracks which framework rendered each reference so a Vue-only page's links point at the .vue.md variants of other references. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01LHNQGac8kwCPEnyPLRYfZu
|
Confirmed both and fixed them in e1bcfe1 (this PR):
The new push also re-runs the website Generated by Claude Code |
…ad-9ry1p8 # Conflicts: # docs/core/api/mockInitialState.md
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01UXvkbVgqm7Uevq8hpMthSS
Requested by Nathaniel · project thread
Follow-up from #4126.
Motivation
Vue had no API page for
DataClientPlugin; mentions linked to the installation page, which only shows a commented-out options list.GCPolicyalso had to be imported from@data-client/core, which Vue users don't install directly, andgcPolicywasn't documented for either framework.Solution
docs/core/api/DataClientPlugin.vue.md(/vue/api/DataClientPlugin): themanagers,initialState,ControllerandgcPolicyoptions (fromcreateDataClient.ts), the$dataClientglobal property, and the note that awaited composables need<script setup>because a hand-writtenasync setup()loses the instance after the firstawait._state_type.mdxand_gc_policy.mdx, used by both DataProvider and DataClientPlugin. DataProvider now documents itsgcPolicyprop, and theStatetype gains the missingfetchedAt.packages/vue/src/context.tsnow links to the new page instead of the React installation docs.Changeset (
@data-client/vuepatch):Verified with
yarn workspace rdc-website build(no broken links; anchors render) and the Vue test suite.Open questions
#4129 already conflicts with master on Manager/DevToolsManager/getDefaultManagers; this PR's one-line link edits there will need to be carried through its rebase.
🤖 Generated with Claude Code
https://claude.ai/code/session_01LHNQGac8kwCPEnyPLRYfZu
Note
Low Risk
Documentation and a public re-export of GCPolicy; no changes to store or plugin runtime behavior beyond dev error URLs.
Overview
Adds a Vue-only API page for
DataClientPlugin(options,$dataClient, composable constraints) and wires it into the Vue sidebar, agent skills, and cross-doc links so Vue setup no longer points at the installation page for plugin configuration.React
DataProviderdocs gain a documentedgcPolicyprop and sharedState/GCPolicypartials (_state_type.mdx,_gc_policy.mdx), including the missingfetchedAtfield on endpoint meta.@data-client/vuenow re-exportsGCPolicy(patch changeset) so Vue apps can configure garbage collection without importing@data-client/core. Dev missing-plugin errors incontext.tslink to/vue/api/DataClientPlugininstead of React installation docs.Skill build (
skillReferences.mjs) tracks which framework rendered each reference file for correct cross-links.Reviewed by Cursor Bugbot for commit 68b2107. Bugbot is set up for automated code reviews on this repo. Configure here.