4 ms·
Not sure about HTML, but you can use `<switch>` [1] in SVG and it will display localized text based on the `system’anguage` property. [1]: https://developer.mo
by Diti 4mo ago
Not sure about HTML, but you can use `<switch>` [1] in SVG and it will display localized text based on the `system’anguage` property.
[1]: https://developer.mozilla.org/en-US/docs/Web/SVG/Reference/Element/switch https://developer.mozilla.org/en-US/docs/Web/SVG/Reference/E...
- Theodores 4mo agoSwitch has some gnarly options with it, and I do want to find an excuse to use it in my 'SVG embroidery sampler'. Flags are a possibility, although I only have the UK flag in my SVG sprite sheet thus far. I will have to see if I can build a usefully stylish locale switcher that gets it right the first time due to browser locale, yet is changeable, with option stored in local storage, all inside the SVG Shadow DOM...