denoland / dotland

[Archived] deno.land website
https://deno.land
MIT License
957 stars 626 forks source link

Set canonical url to the latest version of the same page #2010

Closed kt3k closed 2 years ago

kt3k commented 2 years ago

Google search results sometimes link to the older version of manual. For example, deno web server search shows https://deno.land/manual@v1.14.3/examples/http_server as the first result on my case

Setting the link tag like <link rel="canonical" href="url-of-latest-document" /> should solve this issue. ref. https://developers.google.com/search/docs/advanced/crawling/consolidate-duplicate-urls

kt3k commented 2 years ago

Note: Node.js API docs do the same thing. For example see the source of https://nodejs.org/docs/latest-v16.x/api/fs.html

kt3k commented 2 years ago

Set canonical url 2 weeks ago, but the search result still shows the versioned page for some queries

Is something wrong on our side, or it just takes long time to reflect in the search result? 🤔

kt3k commented 2 years ago

Now most search results seem linking to non-versioned (latest) pages of the manual. (Tested with deno configuration, deno web server, deno permissions etc)