{"id":14156359,"url":"https://github.com/djlint/djlint-vscode","last_synced_at":"2025-08-21T00:31:32.472Z","repository":{"id":43832092,"uuid":"455990543","full_name":"djlint/djlint-vscode","owner":"djlint","description":"VS Code extension for formatting and linting HTML templates (Django, Jinja, Nunjucks, Twig, Handlebars, Mustache).","archived":false,"fork":false,"pushed_at":"2024-10-29T09:32:57.000Z","size":2400,"stargazers_count":53,"open_issues_count":2,"forks_count":2,"subscribers_count":1,"default_branch":"main","last_synced_at":"2024-10-29T11:44:02.649Z","etag":null,"topics":["studio","visual"],"latest_commit_sha":null,"homepage":"https://marketplace.visualstudio.com/items?itemName=monosans.djlint","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/djlint.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2022-02-05T21:32:26.000Z","updated_at":"2024-10-29T09:33:01.000Z","dependencies_parsed_at":"2023-10-02T06:40:40.949Z","dependency_job_id":"c1132564-9816-4c92-8315-e3e5e987167b","html_url":"https://github.com/djlint/djlint-vscode","commit_stats":null,"previous_names":["djlint/djlint-vscode"],"tags_count":61,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/djlint%2Fdjlint-vscode","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/djlint%2Fdjlint-vscode/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/djlint%2Fdjlint-vscode/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/djlint%2Fdjlint-vscode/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/djlint","download_url":"https://codeload.github.com/djlint/djlint-vscode/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":230471175,"owners_count":18231193,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["studio","visual"],"created_at":"2024-08-17T08:05:24.397Z","updated_at":"2024-12-19T17:09:35.131Z","avatar_url":"https://github.com/djlint.png","language":"TypeScript","funding_links":[],"categories":["others"],"sub_categories":[],"readme":"# djlint-vscode\n\n[![CI](https://github.com/djlint/djlint-vscode/actions/workflows/ci.yml/badge.svg)](https://github.com/djlint/djlint-vscode/actions/workflows/ci.yml)\n[![Visual Studio Marketplace Installs](https://img.shields.io/visual-studio-marketplace/i/monosans.djlint?label=Visual%20Studio%20Marketplace%20installs\u0026logo=visualstudio)](https://marketplace.visualstudio.com/items?itemName=monosans.djlint)\n[![Open VSX Downloads](https://img.shields.io/open-vsx/dt/monosans/djlint?label=Open%20VSX%20downloads\u0026logo=vscodium)](https://open-vsx.org/extension/monosans/djlint)\n\nVisual Studio Code extension for formatting and linting HTML templates (Django, Jinja, Nunjucks, Twig, Handlebars, Mustache) using [djLint](https://djlint.com).\n\n## Installation\n\n1. Install djLint itself with the `pip install -U djlint` command.\n1. Install djLint VS Code extension from [Visual Studio Marketplace](https://marketplace.visualstudio.com/items?itemName=monosans.djlint) or [Open VSX](https://open-vsx.org/extension/monosans/djlint).\n\n## Usage\n\nIf you have the [Python extension](https://marketplace.visualstudio.com/items?itemName=ms-python.python) installed, `djlint-vscode` will use the `djLint` installed in the currently activated Python environment, unless you have the `djlint.useVenv` extension setting disabled.\n\nThe extension can be configured through the settings in VS Code. Some options can be configured through the [djLint configuration file](https://djlint.com/docs/configuration/).\n\nAdd this to your `settings.json` to format the default enabled languages with `djLint`:\n\n```json\n\"[html][django-html][handlebars][hbs][mustache][jinja][jinja-html][nj][njk][nunjucks][twig]\": {\n  \"editor.defaultFormatter\": \"monosans.djlint\"\n}\n```\n\n### Usage with djLint installed with pipx\n\n[pipx](https://pypi.org/project/pipx/) creates a separate venv for each application. You can see where it creates the venv with the `pipx environment --value PIPX_LOCAL_VENVS` command. For me it is `/home/user/.local/share/pipx/venvs`. This way I can set these settings:\n\n```json\n\"djlint.useVenv\": false,\n\"djlint.pythonPath\": \"/home/user/.local/share/pipx/venvs/djlint/bin/python\",\n```\n\n### Usage with djLint installed with uv\n\n[uv](https://pypi.org/project/uv/) creates a separate venv for each application. You can see where it creates the venv with the `uv tool dir` command. For me it is `/home/user/.local/share/share/uv/tools`. This way I can set these settings:\n\n```json\n\"djlint.useVenv\": false,\n\"djlint.pythonPath\": \"/home/user/.local/share/share/uv/tools/djlint/bin/python\",\n```\n\n## Known issues\n\n- Non-ASCII characters turn into `?` on Windows after formatting. To fix this, update `djLint` to v1.1.1 or higher.\n\n- Linting does not work on Windows if the file contains non-ASCII characters. To fix this, update `djLint` to v1.1.1 or higher.\n\n- File contents are duplicated after formatting. This is a bug in `djLint` v1.12.1, install another version.\n\n- The config file is ignored on some versions of Python if it is in the root of the project. To fix this, update `djLint` to v1.19.2 or higher.\n\n## License\n\n[MIT](https://github.com/djlint/djlint-vscode/blob/main/LICENSE)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdjlint%2Fdjlint-vscode","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdjlint%2Fdjlint-vscode","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdjlint%2Fdjlint-vscode/lists"}