Add support for Django templates
All of the HTML files for my project (and other Django projects) use Django's template language. It'd be nice to have support for this.
Same goes for .erb templates (ruby)
For Django templates (which is actually file with .html extension) the warning appears Doctype must be declared first. But it is not correct. Because this Django template inherited from base template, in which Doctype exists. Such warnings for Django templates which inherited from other Django templates should check Doctype not in the current file but in its ancestors.
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.
I am still interested in this issue. I hope someone will be able to do this someday.
Thanks @Mogost for the update. Let's see if someone wants to tackle that new feature in the future...
IMO we should do 2 thing with this Issue
- We should look into our codebase if it can survive parsing/hinting template engines like Django and Ruby If not, we need to make this possible
- Then there should be a repo for specialized rules like for Django that exposes some Custom Rules that can be used via load-custom-rules in the first place
So it would be a first start of a plugin system
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.
Bump
Bump!
We are working on a Django project and want to use superlinter, but without this, we have had to enable DISABLE_ERRORS which pretty much defeats the object. Would be great to see this sometime soon.
I have the same issue.
Maybe add support for per-language configuration to have a different set of rules for django-html?
I use template-toolkit, similar issues on parsing files with template directives. Example line that causes issues: <input class = "tabDivButton" type="radio" name="tabSet[%global.tabSetNum%]" id="tab[%global.uid%]" [% IF chk %]checked[% END %]>
still alive and kicking in 2022 with django template files