Skip to content

Commit 12f2a5e

Browse files
authoredNov 8, 2024··
Fix hydration warning due to nested links (#725)
1 parent 8389eb3 commit 12f2a5e

File tree

2 files changed

+5
-7
lines changed

2 files changed

+5
-7
lines changed
 

‎src/components/mdx/link.js

+4-6
Original file line numberDiff line numberDiff line change
@@ -10,16 +10,14 @@ export const Link = React.forwardRef(function CustomLink(props, ref) {
1010

1111
if (isInternalLink) {
1212
return (
13-
<NextLink href={href} passHref>
14-
<ChakraLink ref={ref} {...rest}>
15-
{rest.children}
16-
</ChakraLink>
17-
</NextLink>
13+
<ChakraLink as={NextLink} ref={ref} {...rest}>
14+
{rest.children}
15+
</ChakraLink>
1816
)
1917
}
2018

2119
return (
22-
<ChakraLink isExternal {...rest} ref={ref}>
20+
<ChakraLink isExternal {...rest} as={NextLink} ref={ref}>
2321
{rest.children}
2422
{useExternalIcon && <ExternalLinkIcon mx='2px' />}
2523
</ChakraLink>

‎src/data/sponsors.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ export const Sponsors = [
44
{
55
name: 'CZI',
66
logo: '/Chan_Zuckerberg_Initiative.svg',
7-
url: 'https://chanzuckerberg.com//',
7+
url: 'https://chanzuckerberg.com/',
88
},
99
{ name: 'NVIDIA', logo: '/Nvidia_logo.svg', url: 'https://www.nvidia.com/' },
1010
]

0 commit comments

Comments
 (0)
Please sign in to comment.