Can I change the theme of navbar just for the homepage #826
-
Dear @fuma-nama, I have made a prototye here but I am facing a problem, what I want to do is I want to remove the theme changer just for the homepage and change the navbar to the dark one just for the homepage as it matches the theme. I have checked the docs but it is removing the whole theme from the website, which I don't want as people prefer both the dark and light theme for the docs, is there any thing, I can do to make this thing happen ? Please go to the website and see how the navbar looks if it is in the light theme. Thanks for your help in advanced. |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 2 replies
-
Hmm I see, you can:
'use client';
import { RootProvider } from 'fumadocs-ui/provider';
import type { ReactNode } from 'react';
export function Provider({ children }: { children: ReactNode }) {
return (
<RootProvider>
{children}
</RootProvider>
);
} So that you can invoke |
Beta Was this translation helpful? Give feedback.
In
provider.tsx
:And replace the root provider from root layout with your new one