Language attribute: accessibility requirements

Hello,
I need to add a language attribute (i.e., lang="en-US").
I have defined the language attribute as such in html.Div attributes but when I use an accessibility checker (Siteimprove) it indicates that “language of page has not been set”.

It should look something like this
<!DOCTYPE html>
<html lang=“en-US”>`

thanks!

Solved it with app.index

app.index_string = '''
<!DOCTYPE html>
<html xmlns='http://www.w3.org/1999/xhtml' xml:lang='en' lang='en'>
    <head>
        {%metas%}
        <title>{%title%}</title>
        {%favicon%}
        {%css%}
    </head>
    <body>
        {%app_entry%}
        <footer>
            {%config%}
            {%scripts%}
            {%renderer%}
        </footer>
    </body>
</html>
'''
1 Like