Hi Tom I found this gem:
https://github.com/w3c-validators/w3c_validators The trick would be to integrate it into your view specs. I'm not sure if there's an easy way to do that, but at least there's a place to start. regards Ben On Wednesday, July 20, 2016 at 10:10:19 PM UTC+10, Tom Hale wrote: > > I'm want to check the validity of .html.erb files, at both the erb and > HTML levels. > > I purposely put in weird, unmatched tags to test out rails-erb-lint[1] and > rails-erb-check[2]. I also changed a <% else %> to <% elXse %> and both > said my file was valid. > > So... > > Q1) How do I get feedback on what is actually wrong with my .erb syntax? > > Q2) How can I validate that the eventual HTML output is also valid, and > not just relying on my browser being tolerant? > > Q3) Do many people use erb in production or should I be using something > "better"? Something with a decent error checker? (bonus points for > integrating with vim/syntastic) > > Thanks all, > Tom > > [1] https://rubygems.org/gems/rails-erb-lint/versions/1.1.6 > [2] https://github.com/jugyo/rails-erb-check > -- You received this message because you are subscribed to the Google Groups "Ruby or Rails Oceania" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/rails-oceania/c1570811-cbaa-4678-b873-4c9226df50d0%40googlegroups.com.
