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

(v2) Version label is now mandatory or on by default after upgrading to alpha.62 #3362

Closed
adrianmcli opened this issue Aug 29, 2020 · 12 comments · Fixed by #3381
Closed

(v2) Version label is now mandatory or on by default after upgrading to alpha.62 #3362

adrianmcli opened this issue Aug 29, 2020 · 12 comments · Fixed by #3381
Labels
bug An error in the Docusaurus core causing instability or issues with its execution

Comments

@adrianmcli
Copy link

🐛 Bug Report

Versioning is now imposed on the user since upgrading to alpha.62 (from alpha.61).

As a project that does not want to use versioning in their docs at all, it's weird to have a version label at the top of each page imposed upon us. There's also no clear way to disable this without swizzling.

I would hope that at the very least, there should be an easy way to disable it. But I think it should be off by default.

Have you read the Contributing Guidelines on issues?

Yes.

To Reproduce

  1. Upgrade to alpha.62
  2. Notice that every page now has a Version label at the time

Expected behavior

Nothing should change.

Actual Behavior

Unwanted version label on top of each page.

Screen Shot 2020-08-29 at 2 01 12 AM

@adrianmcli adrianmcli added bug An error in the Docusaurus core causing instability or issues with its execution status: needs triage This issue has not been triaged by maintainers labels Aug 29, 2020
@slorber
Copy link
Collaborator

slorber commented Aug 29, 2020

This is likely a little regression from my big docs plugin refractor. Will be fixed in the next release, in the meantime you can swizzle the comp temporarily.

If you notice other strange behaviors on your unversioned site, please report them 😉 as docusaurus website is versioned there are things I might not see

@MateuszDabrowski
Copy link

The same problem might also impact the custom sidebars approach for doc only page: #3366

@adrianmcli
Copy link
Author

I think I'll stay on alpha.61 for now, but it might be a good idea to have a test case for this. I think not having versioning is much more common than having it.

@slorber
Copy link
Collaborator

slorber commented Aug 31, 2020

@adrianmcli this thing is theme-specific. One theme might choose to show the label while another might not, and you can implement your own theme too :)

Historically the classic theme has no UI test, so it would be odd that I just add one for this particular case when there are so many more tests to write (and I need to make progress on i18n), but yeah that would be great to have more tests here.

@slorber
Copy link
Collaborator

slorber commented Aug 31, 2020

Will be fixed in #3376

ianschmitz added a commit to geocortex/dev-center that referenced this issue Aug 31, 2020
@adrianmcli
Copy link
Author

Thanks @slorber!

slorber added a commit that referenced this issue Sep 1, 2020
* deprecated nextVersionLabel option

* useActivePlugin failfast option

* remove deprecated option nextVersionLabel

* routeBasePath: '' should be forbidden

* routeBasePath: '' should be forbidden

* Docs: do not show version badge if there is only 1 version: #3362

* allow sidebars file to not exist: fallback to empty sidebars
https://githu.com/facebook/docusaurus/issues/3366
slorber added a commit that referenced this issue Sep 1, 2020
)

* deprecated nextVersionLabel option

* useActivePlugin failfast option

* remove deprecated option nextVersionLabel

* routeBasePath: '' should be forbidden

* routeBasePath: '' should be forbidden

* Docs: do not show version badge if there is only 1 version: #3362

* allow sidebars file to not exist: fallback to empty sidebars
https://githu.com/facebook/docusaurus/issues/3366

* Ability to use classic theme/preset while not using docs/pages without trouble.
#3360

* fix netlify redirects

* do not throw if useDocs do not load?

* netlify deploy typo

* try to fix useDocs

* docs(v2): update Deploy to Vercel guide (#3344)

* filter annoying useDocs conditional require warning

* netlify deploy preview homepage

* typo

* try to trigger again CLA bot

Co-authored-by: Sam Ko <sam@vercel.com>
@nabeelio
Copy link

nabeelio commented Sep 2, 2020

I get this error when trying to use disableVersioning: true to try to hide the label too:

Error: Docs: using disableVersioning=true option on a non-versioned site does not make sense

I'm not sure that error makes sense - I want to disable versioning when my site isn't versioned. Is this related? Didn't want to open something new if it is. My docs are in the docs/ dir. But this was attempting to hide that label.

@slorber
Copy link
Collaborator

slorber commented Sep 2, 2020

AFAIK apart swizzling there is no way to disable it in alpha 62, but will release alpha 63 soon.

The error means it's not possible to disable versioning if your site is not versioned. Versioning is indeed already disabled.

@nabeelio
Copy link

nabeelio commented Sep 2, 2020

Yeah I'll wait for an update. And thanks for clarifying, makes sense, I guess I was confused by the version stuff showing up.

@slorber
Copy link
Collaborator

slorber commented Sep 3, 2020

Released in alpha 63 🎊 please spread the word 🙏 and tell me if this works fine for you
https://twitter.com/docusaurus/status/1301562737693138944
https://github.com/facebook/docusaurus/releases/tag/v2.0.0-alpha.63

@nabeelio
Copy link

nabeelio commented Sep 3, 2020

Awesome! I will try it out later tonight and let you know if there are issues!

@nabeelio
Copy link

nabeelio commented Sep 3, 2020

Ok, looks like it's gone now. Had to remove my node_modules directory first and rerun it and seems like the label is gone. Thanks!

@Josh-Cena Josh-Cena removed the status: needs triage This issue has not been triaged by maintainers label Mar 25, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug An error in the Docusaurus core causing instability or issues with its execution
Projects
None yet
Development

Successfully merging a pull request may close this issue.

5 participants