4 ms·
1. Discount, used by both RDiscount and BlueCloth, supports limited use of classes in inline text via pseudo-protocols in link-style tags. You can also use inli
by carbon8 16y ago
1. Discount, used by both RDiscount and BlueCloth, supports limited use of classes in inline text via pseudo-protocols in link-style tags. You can also use inline HTML in markdown. I believe that the latter is what most people do.
2. You can do the equivalent of = in Haml filters by enclosing the Ruby in #{}. For example, where sign_up_path is a Ruby helper method:
:markdown
[Sign Up](#{sign_up_path})
Personally, in the past I've put large blocks of mostly-static content (eg, a TOS) in a erb template or partial. I now often use the markdown filter for things like help documentation in my sites.
- krainboltgreene 16y agoThe :markdown "symbol" doesn't take a class. :markdown.red#item2 %list:markdown.red#item2 %list.red#item2:markdown ...
- carbon8 16y agoForgive me if I'm misunderstanding your point, but :markdown isn't a tag that gets output to html, it just designates the beginning of the block to be processed with markdown, so classes and ids aren't applicable. If you want the markdown block in a class or id, you just do this: #id.class :markdown [A link](/path) outputs: <div id="id" class="class"> <a href="/path">A link</a> </div>