Skip to content

docs(v2) themes - #1645

Merged
endiliey merged 13 commits into
masterfrom
wgao19/docs-themes
Jul 26, 2019
Merged

docs(v2) themes#1645
endiliey merged 13 commits into
masterfrom
wgao19/docs-themes

Conversation

@wgao19

@wgao19 wgao19 commented Jul 9, 2019

Copy link
Copy Markdown

Motivation

Add docs for themes

Have you read the Contributing Guidelines on pull requests?

Yes

Test Plan

NA

Related PRs

#1640

@wgao19
wgao19 requested review from endiliey and yangshun as code owners July 9, 2019 16:21
@wgao19 wgao19 self-assigned this Jul 9, 2019
@facebook-github-bot facebook-github-bot added the CLA Signed Signed Facebook CLA label Jul 9, 2019
@docusaurus-bot

docusaurus-bot commented Jul 9, 2019

Copy link
Copy Markdown
Contributor

Deploy preview for docusaurus-2 ready!

Built with commit 92504a0

https://deploy-preview-1645--docusaurus-2.netlify.com

@docusaurus-bot

docusaurus-bot commented Jul 9, 2019

Copy link
Copy Markdown
Contributor

Deploy preview for docusaurus-preview ready!

Built with commit 92504a0

https://deploy-preview-1645--docusaurus-preview.netlify.com

@wgao19

wgao19 commented Jul 22, 2019

Copy link
Copy Markdown
Author

exemplify swizzling heading #1687

@wgao19
wgao19 force-pushed the wgao19/docs-themes branch from f352ecb to a234f33 Compare July 23, 2019 00:34
@wgao19

wgao19 commented Jul 24, 2019

Copy link
Copy Markdown
Author

Hey @endiliey @yangshun these docs are ready for a round of review. Please let me know what you think and places to improve.

There are quite some changes around how plugins and themes docs are organized. Please make sure you browse around these sections on the preview sites to get a feeling that they make sense:

  • Guides: Using Plugins
  • Guides: Using Themes
  • Advanced Guides: Themes

I've also combined the API docs for themes and plugins to a file called Lifecycle APIs because themes and plugins share the same lifecycle methods.

@endiliey endiliey left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

some suggestions and typo

will rereview again

Comment thread website/docs/using-plugins.md Outdated
'@docusaurus/plugin-content-pages',
[
// Plugin with options
'@docusaurus/plugin-content-blog',

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

since passing options is mentioned in the next section, lets simplify this part

Comment thread website/docs/using-plugins.md Outdated
A plugin is an npm package, so you install them like other npm packages using npm.

```bash
yarn add docusaurus-plugin-name

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

use npm

Comment thread website/docs/using-themes.md Outdated
As an example, to swizzle the `<Footer />` component in `@docusaurus/theme-classic` for your site, run:

```shell
$ yarn swizzle @docusaurus/theme-classic

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

typo here.

npm swizzle @docusaurus/theme-classic Footer

- [@docusaurus/plugin-content-pages](https://github.com/facebook/docusaurus/tree/master/packages/docusaurus-plugin-content-pages)
- [@docusaurus/plugin-google-analytics](https://github.com/facebook/docusaurus/tree/master/packages/docusaurus-plugin-google-analytics)
- [@docusaurus/plugin-google-gtag](https://github.com/facebook/docusaurus/tree/master/packages/docusaurus-plugin-google-gtag)
- [@docusaurus/plugin-sitemap](https://github.com/facebook/docusaurus/tree/master/packages/docusaurus-plugin-sitemap)

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

mention plugin ideal image too

Themes provide the consistent components for your doc sites.

<!-- TODO: WIP intro -->

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

i find it hard to understand themes without reading advanced guide-themes. I think we should try giving user understanding of themes first before teaching them how to use it. Not really sure whats the best approach

@wgao19

wgao19 commented Jul 24, 2019

Copy link
Copy Markdown
Author

@endiliey updated

@wgao19

wgao19 commented Jul 26, 2019

Copy link
Copy Markdown
Author

@endiliey removed it and replaced with the theme folder

@wgao19 wgao19 changed the title WiP: docs(v2) themes docs(v2) themes Jul 26, 2019
@endiliey
endiliey merged commit f4f4584 into master Jul 26, 2019
@endiliey

Copy link
Copy Markdown
Contributor

we can always tweak. merged

@wgao19 wgao19 mentioned this pull request Jul 26, 2019
20 tasks
@endiliey
endiliey deleted the wgao19/docs-themes branch August 6, 2019 07:17
mrizwanashiq pushed a commit to mrizwanashiq/docusaurus that referenced this pull request Jun 25, 2026
* More prep

* rename xxx-api to api-xxx

* move content around for plugins and themes

* wip docs: using themes

* docs(v2): tweak using plugins

* docs(v2): list official themes in docs

* docs(v2): advanced themes

* wip notes for lifecycle apis

* resolve PR review discussions

* lower case "theme"

* better intro for using themes

* add a simple README to @docusaurus/theme-classic

* remove list of components from theme classic README and replace with link to directory
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

CLA Signed Signed Facebook CLA

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants