[Proposal] Add a linter for Django templates
I was looking at a PR and wanted to suggest that {{example}} should be {{ example }}
Perhaps a linter, such djade, can be used to prevent the need for these suggestions š
Hi @sarahboyce, I would like to work on this issue. I can add djade to the project's configuration to automate these template formatting checks (like {{ example }}) and prevent future style inconsistencies. Could you please assign this to me?
Great idea.
I've used djLint before.
https://github.com/djlint/djLint
I'm not opposed.
Thanks for the suggestion @marksweb!
@sarahboyce @adamzap ā Do you guys have a preference here? Iām happy to pick this up using djade (as originally proposed), or I can look into djLint if you think that's better.
Just let me know which direction you want to go so I can get started on the PR!
@aNsHuL5217 this project is managed by the website working group. Before something like this can be merged, we would need the team to agree it should be done š You're welcome to make a draft PR but be aware that this proposal may not be accepted. As this is a volunteer run project, it may take a month or so before there is clear agreement this should be implemented
I think this is a good idea. I think I personally would prefer djade over djLint since the djLint readme says Maintainers needed, please reach out on discord or email! currently. @aNsHuL5217 if you would like to open a PR, that would be great! We can discuss it more while reviewing the PR, but as Sarah said, given this is a volunteer run project, it can take some time to get merged / agreed upon the correct way to do this while reviewing the PR.
Thanks @SaptakS, that makes perfect sense regarding djLint's maintenance status. I'll stick with djade as planned and open a PR shortly!
Hi @SaptakS, thanks for the guidance!
I have opened a Draft PR here
It implements djade (v1.6.0) and formats the existing templates as discussed. I'll wait for the Working Group's review.
We already have the PR (thanks @aNsHuL5217 ) but I wanted to express my support. Linters all the way š š (š)