HTML files recognized as Django Template in VS Code

image for the same

1) Click on "select language mode" from bottom right toolbar.

2) Select "Configure file association for .html" from the dropdown.

3) Select html from the dropdown.

This will remove html file being marked as Django-html every time you create a html document.


Include the following line of setting emmet.includeLanguages": {"django-html": "html"} in VSCode's settings.json:

{
  "python.jediEnabled": false,
  "files.autoSave": "afterDelay",
  "editor.suggestSelection": "first",
  "vsintellicode.modify.editor.suggestSelection": "automaticallyOverrodeDefaultValue",
  "editor.minimap.enabled": true,
  "workbench.colorTheme": "Monokai",
  "editor.largeFileOptimizations": false,
  "html.format.indentInnerHtml": true,
  "html.format.indentHandlebars": true,
  "emmet.includeLanguages": {
    "django-html": "html"
  },
  "[django-html]": {

  },
  "files.associations": {
    "*.html": "html"
  }
}

It does the fix for me on version 1.33.1


These settings worked for me in vscode settings.json

"files.associations": {
    "**/templates/*.html": "django-html",
    "**/templates/*": "django-txt",
    "**/requirements{/**,*}.{txt,in}": "pip-requirements",
    "*.html": "html"
  },
  "emmet.includeLanguages": { "django-html": "html" }

Solved! I began eliminating extensions and found that Django Template 1.2.0 (bibhasdn.django-html) is to blame. As soon as I disabled it, the HTML option returned to the Language Associations menu. Hat tip to @ifconfig for confirming I should expect it to be present.