-
-
Notifications
You must be signed in to change notification settings - Fork 1.3k
docs: fix import path for useSession in authentication.md #5318
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
Conversation
WalkthroughDocumentation updated to reflect importing useSession from TanStack Start’s server-specific entry point. The doc shows replacing imports in utils/session.ts with @tanstack/react-start/server, noting both occurrences. Changes
Estimated code review effort🎯 1 (Trivial) | ⏱️ ~2 minutes Poem
Pre-merge checks and finishing touches✅ Passed checks (3 passed)
✨ Finishing touches🧪 Generate unit tests
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. Comment |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 0
🧹 Nitpick comments (1)
docs/start/framework/react/authentication.md (1)
375-388: Consider adding import statement for consistency.This second example also uses
useSession(line 378) but doesn't show the import statement. For consistency with the first example at line 98 and to help readers, consider adding the import statement at the beginning of this code block as well.Add the import at the start of the code block:
// Use secure session configuration +import { useSession } from '@tanstack/react-start/server' + export function useAppSession() { return useSession({
📜 Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro
📒 Files selected for processing (1)
docs/start/framework/react/authentication.md(1 hunks)
🧰 Additional context used
📓 Path-based instructions (2)
docs/**/*.{md,mdx}
📄 CodeRabbit inference engine (AGENTS.md)
Use internal docs links relative to the docs/ folder (e.g., ./guide/data-loading)
Files:
docs/start/framework/react/authentication.md
docs/{router,start}/**
📄 CodeRabbit inference engine (AGENTS.md)
Place router docs under docs/router/ and start framework docs under docs/start/
Files:
docs/start/framework/react/authentication.md
🔇 Additional comments (2)
docs/start/framework/react/authentication.md (2)
98-98: LGTM! Correct import path for server-side session management.The change to import
useSessionfrom@tanstack/react-start/serveris correct, as this is server-side session functionality that should be imported from the server-specific entry point.
609-609: Verify internal documentation link format.The link
/router/latest/docs/framework/react/how-to/README.md#authenticationuses an absolute path. According to the coding guidelines, internal docs links should be relative to the docs/ folder (e.g.,./guide/data-loading).As per coding guidelines.
Please verify if this link should be updated to use a relative path format consistent with the other internal links in this file (like
../authentication-overview.md).
|
View your CI Pipeline Execution ↗ for commit 30c79d8
☁️ 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-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: |
Summary by CodeRabbit