Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(v2): allow skipping build docs for next version #2877

Merged
merged 6 commits into from
Jun 25, 2020

Conversation

lex111
Copy link
Contributor

@lex111 lex111 commented Jun 4, 2020

Motivation

Resolve #2813

Have you read the Contributing Guidelines on pull requests?

Yes

Test Plan

  1. In the config file for docs set the excludeNextVersionDocs field with the true value.
  2. Try running dev server running yarn start and make sure that docs are accessible by docs/next path
  3. Try building the site running yarn build and make sure build/docs/next dir does not exist.
  4. Remove excludeNextVersionDocs filed and build site again, and make sure build/docs/next dir appears.

Related PRs

(If this PR adds or changes functionality, please take some time to update the docs at https://github.com/facebook/docusaurus, and link to your PR here.)

@lex111 lex111 added the pr: new feature This PR adds a new API or behavior. label Jun 4, 2020
@lex111 lex111 requested a review from yangshun June 4, 2020 08:49
@facebook-github-bot facebook-github-bot added the CLA Signed Signed Facebook CLA label Jun 4, 2020
@docusaurus-bot
Copy link
Contributor

docusaurus-bot commented Jun 4, 2020

Deploy preview for docusaurus-2 ready!

Built with commit 5cfb3db

https://deploy-preview-2877--docusaurus-2.netlify.app

@lex111
Copy link
Contributor Author

lex111 commented Jun 5, 2020

cc @yangshun

@slorber slorber merged commit bdffd28 into master Jun 25, 2020
@slorber
Copy link
Collaborator

slorber commented Jun 25, 2020

lgtm

@amimas
Copy link

amimas commented Jun 25, 2020

Thanks a lot for bringing this feature from V1. Will this also generate the sitemap without the next release docs if the option is enabled? I couldn't tell from the changes in this PR.

@slorber
Copy link
Collaborator

slorber commented Jun 26, 2020

yes the next paths should not appear in the sitemaps because we don't add any react router route for the next paths (which are read by the sitemaps plugin)

Tell me if this does not work for you once we release

@amimas
Copy link

amimas commented Jun 26, 2020

Perfect!! Thank you. Will try it out.

@yangshun yangshun deleted the lex111/docs-skip-next-release branch June 30, 2020 14:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
CLA Signed Signed Facebook CLA pr: new feature This PR adds a new API or behavior.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

(V2) Option to skip next release docs during build
5 participants