The initial docsearch config for our site
docs.contao.org was made in such a way, that the language attribute is extracted from the URL:
However, the Contao docs consist of the developer documentation under
docs.contao.org/dev and the manual under
docs.contao.org/manual. Only the latter is available in multiple languages and thus only the latter will have the language present in the URL.
This also means that currently the
language attribute is missing from the scraped
dev docs completely, which makes more difficult for facet filtering. But, both the dev docs and the manual have a
lang attribute in their
<html> tag. Since this information is already available and it would be more consistent: is there a way to tell the docsearch config to extract the language from the
<html lang="…"> attribute instead? I am not sure how the config would need to be changed in order to achieve this.