dense-analysis / ale

Check syntax in Vim/Neovim asynchronously and fix files, with Language Server Protocol (LSP) support
BSD 2-Clause "Simplified" License
13.55k stars 1.44k forks source link

Any Linter for Jinja files ? #1710

Open jkryanchou opened 6 years ago

jkryanchou commented 6 years ago

Is there any linter for Jinja files ? I have write html with jinja2 template engine. While when i editing the jinja file. HTMLhint couldn't lint the file well.

w0rp commented 6 years ago

You could be the first to add one.

jkryanchou commented 6 years ago

uhha OK. I would like to add new one to lint Jinja files.

w0rp commented 6 years ago

I noticed that this is a duplicate of #627.

Migacz85 commented 5 years ago

So how to achive linting in jinja template files ? I want to lint template.html file but using ALEFix tidy - will treat this just as simple html file and will generate what normaly template language should generate. And calling ALEFix prettier will not run on template.html file becausee is html files are in partials and prettier will treat template.html file as a broken html file.

Any ideas how this should be setup to just prettier the template language code? and if possible Lint and Prettify the code ?

Thanks

davidjb commented 5 years ago

@w0rp Could you please reopen / unmark as duplicate; that linked issue is about julia (programming lang) is different to jinja2 (templating lang)

w0rp commented 5 years ago

Sure, thank you for pointing that out.

nospam2998 commented 1 month ago

The previously listed issue might have been misidentified, but I'm quite sure #2316 is a true duplicate of this.

Maybe someone of those having shown interest could hack up some j2lint support and close both issue? (or perhaps @jkryanchou would like to close this one, as the other one is more specific and actionable?)