mirror of
https://github.com/facebook/docusaurus.git
synced 2025-06-02 19:03:38 +02:00
docs(v2): command for swizzling all components (#2549)
* doc(v2): Add swizzle all components doc * Update using-themes.md Co-authored-by: Yangshun Tay <tay.yang.shun@gmail.com>
This commit is contained in:
parent
49a2958c96
commit
6a20183a68
1 changed files with 7 additions and 1 deletions
|
@ -93,7 +93,13 @@ npm run swizzle @docusaurus/theme-classic Footer
|
|||
|
||||
This will copy the current `<Footer />` component used by the theme to a `src/theme/Footer` directory under the root of your site, which is where Docusaurus will look for swizzled components. Docusaurus will then use swizzled component in place of the original one from the theme.
|
||||
|
||||
**Note**: You need to restart your dev server for Docusaurus to pick up the new component.
|
||||
Although we highly discourage swizzling of all components, if you wish to do that, run:
|
||||
|
||||
```bash npm2yarn
|
||||
npm run swizzle @docusaurus/theme-classic
|
||||
```
|
||||
|
||||
**Note**: You need to restart your webpack dev server in order for Docusaurus to know about the new component.
|
||||
|
||||
## Official themes by Docusaurus
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue