djLint is a mustache template linter and a mustache template formatter! Take advantage of the pre-built profile when linting and formatting your templates with djLint.
djlint /path/to/templates --profile=handlebars
Configure djLint in your projects pyproject.toml.
[tool.djlint]
profile="handlebars"