You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
head: functionHead(){constconfig=useConfig();consttitle=`${config.title} | Site Name`;return(<><title>{title}</title></>);},
No idea why these would be different, but this works without the issue. Really easy fix so not sure if this is worth a bug report but I thought it'd be worth documenting in an issue here at least, in case others have the issue in the future.
Describe the bug
Ran into an issue using the useConfig hook for head() - when I tried to use code like this in the theme config file:
My title initially loaded as e.g.
Introduction<!-- --> | Site Name
for a moment before re-rendering without the odd<!-- -->
:chrome_2024-11-25_14-53-31.mp4
I followed the code for the nextra site itself exactly by extracting a
title
variable, like so:No idea why these would be different, but this works without the issue. Really easy fix so not sure if this is worth a bug report but I thought it'd be worth documenting in an issue here at least, in case others have the issue in the future.
Reproduction
I deployed my changes to a branch:
Desktop (please complete the following information):
The text was updated successfully, but these errors were encountered: