lang attribute in html element
See original GitHub issue[ ] bug report => check the FAQ and search github for a similar issue or PR before submitting
[ ] support request => check the FAQ and search github for a similar issue before submitting
[X] feature request
Current behavior The html element in the DOM don’t has the lang attribute.
Expected/desired behavior
Having the lang attribute in html element.
The DOM must look like:
<html lang="en">
What is the motivation / use case for changing the behavior? Be more standard on language identification for SEO or other tools.
-
ngx-translate version: 6.0.1
-
Angular version: 4.0.1
-
Browser: [all]
Issue Analytics
- State:
- Created 6 years ago
- Comments:19
Top Results From Across the Web
HTML Global lang Attribute - W3Schools
The lang attribute specifies the language of the element's content. Common examples are "en" for English, "es" for Spanish, "fr" for French, and...
Read more >Using the HTML lang attribute - TPGi
The HTML lang attribute is used to identify the language of text content on the web. This information helps search engines return language ......
Read more >lang - HTML: HyperText Markup Language - MDN Web Docs
The lang global attribute helps define the language of an element: the language that non-editable elements are written in, or the language ...
Read more >Declaring language in HTML - W3C
The xml:lang attribute is the standard way to identify language information in XML. Ensure that the values for both attributes are identical.
Read more ><html> element must have a lang attribute | Axe Rules
Add a lang attribute to the html element (e.g. <html lang="en"> ) whose value represents the primary language of document. Make sure you...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
As wokaround it’s possible to subscribe to onLangChange in the app.component and modify the DOM via
ElementRef
.My code:
Maybe can be done as a new parameter to the module (what do you think about
reflectInHtml
)