I want to detect the current site/frontend language within Javascript. How can I do to register the language for use within?
1 Answer
According to https://stackoverflow.com/questions/662923/extract-lang-value-using-javascript you can use document.documentElement.lang