Skip to main content

Django Template Linter

Project description

djLint Logo

Simple html template linter and reformatter to find common formatting issues. djLint is intended as a django template linter and django template formatter.

Ps, --check it out on Jinja and Handlebar templates as well!

codecov test Codacy Badge Maintainability Downloads

Documentation

Read the documentation

Installation and Usage

djLint can be installed with pip install djlint, and is easy to run:

# to lint a directory
djlint /path

# to lint a directory with custom extension
djlint /path -e html.dj

# to check formatting on a file
djlint /path/file.html.j2 --check

# to reformt a directory without printing the file diff
djlint /path --reformat --quiet

Show your format

Add a badge to your projects readme.md:

[![Code style: black](https://img.shields.io/badge/html%20style-djlint-blue.svg)](https://github.com/Riverside-Healthcare/djlint)

Add a badge to your readme.rst:

.. image:: https://img.shields.io/badge/html%20style-djlint-blue.svg
   :target: https://github.com/Riverside-Healthcare/djlint

Looks like this:

djlint

Contributing - Please Help!

Checkout the issue list and help where you can!

Changelog

0.0.8

Added rules.

0.0.1

Initial release.

Project details


Release history Release notifications | RSS feed

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

djlint-0.1.6.tar.gz (374.8 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

djlint-0.1.6-py3-none-any.whl (26.1 kB view details)

Uploaded Python 3

File details

Details for the file djlint-0.1.6.tar.gz.

File metadata

  • Download URL: djlint-0.1.6.tar.gz
  • Upload date:
  • Size: 374.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.4.1 importlib_metadata/4.6.1 pkginfo/1.7.1 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.61.2 CPython/3.8.0

File hashes

Hashes for djlint-0.1.6.tar.gz
Algorithm Hash digest
SHA256 bfc3cb27d09cb0f928c327384a4e981083c68e717663700277a1f4097e74de3c
MD5 aea78e487203ef7c77e45d34243b71ee
BLAKE2b-256 94728f906dc777aba2e4c796a3e61d0c032b093416805c2c081b984059162169

See more details on using hashes here.

File details

Details for the file djlint-0.1.6-py3-none-any.whl.

File metadata

  • Download URL: djlint-0.1.6-py3-none-any.whl
  • Upload date:
  • Size: 26.1 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.4.1 importlib_metadata/4.6.1 pkginfo/1.7.1 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.61.2 CPython/3.8.0

File hashes

Hashes for djlint-0.1.6-py3-none-any.whl
Algorithm Hash digest
SHA256 0e04d0a058ac3586ac8c7f6a614c76c0f3f96e884ec3b8fd7529f8274bbf8a1c
MD5 866d05272946e3c8424c0c4db2312fcc
BLAKE2b-256 e70cd14ae055cc8404bf36f414c929361f752e0cecc8acf949d5637a39a56547

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page