Haml in Maruku Filter

393 Views Asked by At

For this project, I need to be able to mix Haml tags within the Maruku filter. For example, will I be able to do this:

#contain
  :maruku
    ## Hello H2 Tag
      div{:id => 'divinmaruku'}
        **Can I do this?**

I know you can just unindent where you want to get out Maruku, but it is a pain to do :maruku whenever I want to use it.

1

There are 1 best solutions below

0
Natalie Weizenbaum On BEST ANSWER

No, you can't do this (at least, not without hacking Maruku so that it calls out to Haml). You can insert literal HTML, or use Maruku's div syntax:

+-----------{#divinmaruku}---
| **You can do this**
+----------------------------

This renders as

<div id='divinmaruku'>
<p><strong>You can do this</strong></p>
</div>