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

Link latest documentation from old documentation #9519

Closed
1 of 3 tasks
not-my-profile opened this issue Aug 6, 2021 · 1 comment · Fixed by #10446
Closed
1 of 3 tasks

Link latest documentation from old documentation #9519

not-my-profile opened this issue Aug 6, 2021 · 1 comment · Fixed by #10446

Comments

@not-my-profile
Copy link

Documentation Is:

  • Missing or needed
  • Confusing
  • Not Sure?

Please Explain in Detail...

When I google for Chart.js documentation Google sometimes returns old documentation, which is particularly sneaky because Google hides the URL, for example:

image

leads to https://www.chartjs.org/docs/2.9.4/configuration/tooltip.html which doesn't at all say that this isn't the latest version.

Your Proposal for Changes

I think it would be nice to do something like the Rust docs.rs which displays image when viewing out of date documentation.

@igorlukanin
Copy link
Member

igorlukanin commented Jun 28, 2022

I think a couple of things can be done to mitigate this:

  • update the dropdown menu with a stale versions warning
  • add the robots.txt file

Stale version warning

We can show a visible warning for all numbered versions that will suggest checking the lastest version of the docs. IDK if a 5-word warning is too ugly—I think it might be okay since is should attract the attention.

We can also add a dedicated link to the latest version alongside the link to the development version.

I've submitted a PR with these changes: #10446

Please see how it works:
Screenshot 2022-06-28 at 18 47 05

robots.txt file

We can add the robots.txt file to discourage Google from indexing all versions of the documentation pages except for the "latest" and "master".

It doesn't prevent these pages from being indexed completely—Google will still index them if there are any links to these pages (which is a good thing); however, this should remove most of the "stale" documentation pages from the index.

It will also remove the "most recent numeric version" pages from the index (as of this moment, it's https://www.chartjs.org/docs/3.8.0/); it seems to be okay since the same content is available as the "latest" versions (https://www.chartjs.org/docs/latest/).

I've submitted a PR with these changes: chartjs/www.chartjs.org#15

I've also tested them with a robots.txt checker. Please see screenshots:

@etimberg @kurkle @LeeLenaleee @not-my-profile What do you think?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants