getgrav / grav-plugin-langswitcher

Grav LangSwitcher Plugin
https://getgrav.org
MIT License
28 stars 26 forks source link

Adding x-default fallback? #41

Closed marcocevoli closed 2 years ago

marcocevoli commented 6 years ago

Hi, I might be mistaken, but the plugin currently doesn't output the fallback tag/attribute, such as

<link rel="alternate" hreflang="x-default" href="https://www.example.com/" />

According to this article, https://www.contentkingapp.com/academy/hreflang/, the fallback should always be there for SEO reasons.

Any chances that you might add it?

TIA

rhukster commented 6 years ago

i'll add it to the list...

steopcik commented 5 years ago

i'll add it to the list...

Hi, this feature was added or not?

rhukster commented 2 years ago

I know its very late to the party, but i've now added an x-default entry when the language is default and the include_default_lang option in system.yaml is set to false. So default lang URLs with no lang prefix will get this x-default entry.