Google results for date-fns functions return out-dated materials #2582
Replies: 3 comments 2 replies
-
@Chrisazy thanks for reporting this. Much appreciated! |
Beta Was this translation helpful? Give feedback.
-
There certainly are a number of issues with the documentation from an SEO perspective, it should probably be re-architected. It doesn't seem like Googlebot can properly crawl the docs contents to begin with, so there are no deeplinks when you search for the documentation of a function. ex: Googling "date-fns docs parseISO", I get these awful results:
The URLs containing the full semver certainly brings some issues too. In my opinion, it would be better to have 1.x and 2.x "evergreen" urls, and also use those as canonical link for existing semver urls. These are the ones you'd want search engine crawlers and most documentation readers to use / share. A more prominent warning on pages that are not the latest version would also help, especially for users coming from old Stackoverflow answers or github issues/discussions that contained semver links. Projects like Jest and Laravel seem to do a good job at these specifically, perhaps their approach could be referenced. |
Beta Was this translation helpful? Give feedback.
-
Thanks for the feedback and ideas everyone! Appreciated! |
Beta Was this translation helpful? Give feedback.
-
Every time I go to search for the API specs of a date-fns function (looking at you, format) I end up at the version 1.9.0 documentation. According to npm numbers, this version is neither the most recent nor the most popular (1 download this past week). I understand that 1.30 is still a very popular version of the package, but the average user will either be aware that they're on a legacy version (1.X) and ensure they're on that version of the API spec, or they'll probably not know that there are popular older versions, in which case they'll have no idea the docs aren't showing the latest version by default.
All of that being said, I obviously don't know if this is intentional or not. It could just be that the docs website needs to be updated so that search engines will prefer the latest versions of the functions for search results. It's pretty frustrating for a google result to bring you to a page that's been out of date for nearly 4 years.
Beta Was this translation helpful? Give feedback.
All reactions