documentation
documentation copied to clipboard
Show search results when a 404 is returned
I recently encountered some 404s on the documentation and add an idea, why can't we just display results for the best results for a given URL. We could extract the components of the queried URL and query the documentation search engine for it.
Note that those links could have been stored on other websites than the documentation itself and therefore a simple scan for dead links would not be enough. And it would be great that the documentation page of a search engine always returns relevant results 😄
As an example, this old filtering documentation page URL is no more accessible but if we extract the last URL components (i.e. reference, features, filtering) give perfect results.

Great idea! I wonder whether this issue should be here or in MeiliSearch/docs-scraper. WDYT @curquiza ?
Hello!
A hypothesis is the scraper runs BEFORE the deployment on Netflify is finished. It's totally possible because the scraper job is not related to the deployment and does not wait for the end of the Netlify deployment to run (since we are using Netlify instead of GitHub Pages)... Cf this issue: https://github.com/meilisearch/documentation/issues/551
Thus, the scraper scrapes the old website and then, after it runs, the new one is deployed.
Thanks, I see what you mean but 404s not only happened because of this. Sometimes we can have an external link to the documentation that direct to old URLs that are no longer alive.
What @Kerollmops is talking about, is an enhancement of the UX using MeiliSearch.
Example
Some random website is linking to a tutorial on the documentation that is no longer existing. We could extract the keywords in the URL in order to send them to MeiliSearch and display on the 404 a message like "404 The page you are looking for does not exist, but you might be interested in those pages: [insert MeiliSearch results]
In my previous comment, I didn't mean docs-scraper but MeiliSearch/docs-searchbar.js. Should this issue belong there?
Checked with Kero, I understand better! :)
I think this implementation cannot come from docs-searchbar.js since this package only handles the search box and not the whole page. It should be implemented on the documentation side if I'm correct!
This issue is now the responsibility of an external team and will be monitored in their preferred platform.
Hey @guimachiavelli 👋
Have you informed them about this issue?
Hello @Kerollmops Yes, gui reported all the closed issues to the right place