Skip to content
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

Fix typo in the Link component doc #74333

Open
wants to merge 1 commit into
base: canary
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 8 additions & 8 deletions docs/01-app/04-api-reference/02-components/link.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -1130,10 +1130,10 @@ In this case, you would want to use the following code in your `<Link />` compon
'use client'

import Link from 'next/link'
import useIsAuthed from './hooks/useIsAuthed' // Your auth hook
import userIsAuthed from './hooks/userIsAuthed' // Your auth hook

export default function Page() {
const isAuthed = useIsAuthed()
const isAuthed = userIsAuthed()
const path = isAuthed ? '/auth/dashboard' : '/public/dashboard'
return (
<Link as="/dashboard" href={path}>
Expand All @@ -1147,10 +1147,10 @@ export default function Page() {
'use client'

import Link from 'next/link'
import useIsAuthed from './hooks/useIsAuthed' // Your auth hook
import userIsAuthed from './hooks/userIsAuthed' // Your auth hook

export default function Page() {
const isAuthed = useIsAuthed()
const isAuthed = userIsAuthed()
const path = isAuthed ? '/auth/dashboard' : '/public/dashboard'
return (
<Link as="/dashboard" href={path}>
Expand All @@ -1168,10 +1168,10 @@ export default function Page() {
'use client'

import Link from 'next/link'
import useIsAuthed from './hooks/useIsAuthed' // Your auth hook
import userIsAuthed from './hooks/userIsAuthed' // Your auth hook

export default function Home() {
const isAuthed = useIsAuthed()
const isAuthed = userIsAuthed()
const path = isAuthed ? '/auth/dashboard' : '/public/dashboard'
return (
<Link as="/dashboard" href={path}>
Expand All @@ -1185,10 +1185,10 @@ export default function Home() {
'use client'

import Link from 'next/link'
import useIsAuthed from './hooks/useIsAuthed' // Your auth hook
import userIsAuthed from './hooks/userIsAuthed' // Your auth hook

export default function Home() {
const isAuthed = useIsAuthed()
const isAuthed = userIsAuthed()
const path = isAuthed ? '/auth/dashboard' : '/public/dashboard'
return (
<Link as="/dashboard" href={path}>
Expand Down
Loading