0

What I'd like to do:

I'd like to use rmarkdown to create rails *.html.erb files.

If you're unfamiliar with *.html.erb files, they're basically html files with ruby enclosed between <% and %> or between <%= and %> (latter if result should be included in final html rendering).

Problem:

I can not find a way to get rmarkdown to ignore <%, %>, <%= and everything between them.

Q: Any ideas how this might be done?

Thanks in advance.

Morten Grum
  • 962
  • 1
  • 10
  • 25
  • I guess you could write a [pandoc filter](http://pandoc.org/scripting.html) to convert code blocks with your special stuff to raw HTML. alternatively: http://stackoverflow.com/questions/4163560/how-can-i-automatically-render-partials-using-markdown-in-rails-3/10131299#10131299 – mb21 Jun 14 '16 at 15:01
  • Perfect. Best solution for me is indeed in http://stackoverflow.com/questions/4163560/how-can-i-automatically-render-partials-using-markdown-in-rails-3/10131299#10131299 Thanks @mb21 – Morten Grum Jun 16 '16 at 04:23

0 Answers0