Swizzling footer #8022
-
|
I have swizzled footer component, using "npm run swizzle @docusaurus/theme-classic Footer -- --eject" I have done eject because I wanted to use this footer in specific files only. Now after running this command, a folder is created.
Now how to proceed, I tried to import this footer component in another js file and tried using it as a tag , like But its not working. Can I know how to use the swizzled component after swizzling? |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 1 reply
-
|
The footer component is a part of the If you want to display it conditionally, you can make it render
What is not working exactly: please create a repro. You are not necessarily supposed to "use" swizzled components. They are already "used" by Docusaurus itself, and you mostly need to customize them. |
Beta Was this translation helpful? Give feedback.
The footer component is a part of the
@theme/Layoutcomponent.If you want to display it conditionally, you can make it render
nullinside the Footer, or not render it at all by swizzling the@theme/Layoutcomponent insteadWhat is not working exactly: please create a repro.
You are not necessarily supposed to "use" swizzled components. They are already "used" by Docusaurus itself, and you mostly need to customize them.