-
-
Notifications
You must be signed in to change notification settings - Fork 1.4k
Add jsdoc annotations to public api #5574
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add jsdoc annotations to public api #5574
Conversation
Co-authored-by: tannerlinsley <tannerlinsley@gmail.com>
|
Cursor Agent can help with this pull request. Just |
|
Caution Review failedThe pull request is closed. WalkthroughThis PR enhances documentation and expands public APIs across react-router and router-core packages. It adds JSDoc comments throughout, introduces new utility functions (path trimming, redirect parsing, rewrite composition, scroll handling), exports existing internal utilities, and adds a new Await component for handling deferred promises. Changes
Estimated code review effort🎯 3 (Moderate) | ⏱️ ~25 minutes The changes span multiple files with a mix of documentation additions (low complexity) and new functional APIs (moderate complexity). Most of the heterogeneity comes from documentation improvements, which are repetitive and straightforward. However, the new rewrite utilities, redirect parsing functions, and scroll restoration exports require careful logic review. The router.ts file's potential method duplication warrants particular attention. Possibly related PRs
Suggested reviewers
Poem
✨ Finishing touches
🧪 Generate unit tests (beta)
📜 Recent review detailsConfiguration used: CodeRabbit UI Review profile: CHILL Plan: Pro 📒 Files selected for processing (13)
Comment |
|
View your CI Pipeline Execution ↗ for commit af3d35a
☁️ Nx Cloud last updated this comment at |
More templates
@tanstack/arktype-adapter
@tanstack/directive-functions-plugin
@tanstack/eslint-plugin-router
@tanstack/history
@tanstack/nitro-v2-vite-plugin
@tanstack/react-router
@tanstack/react-router-devtools
@tanstack/react-router-ssr-query
@tanstack/react-start
@tanstack/react-start-client
@tanstack/react-start-server
@tanstack/router-cli
@tanstack/router-core
@tanstack/router-devtools
@tanstack/router-devtools-core
@tanstack/router-generator
@tanstack/router-plugin
@tanstack/router-ssr-query-core
@tanstack/router-utils
@tanstack/router-vite-plugin
@tanstack/server-functions-plugin
@tanstack/solid-router
@tanstack/solid-router-devtools
@tanstack/solid-router-ssr-query
@tanstack/solid-start
@tanstack/solid-start-client
@tanstack/solid-start-server
@tanstack/start-client-core
@tanstack/start-plugin-core
@tanstack/start-server-core
@tanstack/start-static-server-functions
@tanstack/start-storage-context
@tanstack/valibot-adapter
@tanstack/virtual-file-routes
@tanstack/zod-adapter
commit: |
Add JSDoc annotations to key public APIs in
@tanstack/router-coreand@tanstack/react-routerfor improved self-documentation.This PR annotates over 20 core router functions, path utilities, search param helpers, rewrite logic, scroll restoration, and React hooks/components. The JSDoc focuses on describing behavior and options, complementing existing TypeScript types.
Summary by CodeRabbit
Release Notes
New Features
Awaitcomponent for handling deferred promises with suspense supporttrimPathLeft,trimPathRight,trimPathImprovements
Documentation