Using tags such as bold or italic in slim?

Ty Strong picture Ty Strong · Jan 1, 2014 · Viewed 8.5k times · Source

Let's say I have this code in HTML:

<p>Lorem ipsum, <b>volutpat</b>. Ut wisi enim ad minim veniam.</p>

How would I convert that to slim? Throughout all of Slim's documentation, it never once mentions bold, italic, or any other inline elements. I tried this:

p Lorem ipsum, b volutpat. Ut wisi enim ad minim veniam.

As expected it just added a 'b' to the text. I also tried using tubes:

p Lorem ipsum, 
  | b volutpat.
  | Ut wisi enim ad minim veniam.

This gave me the exact same result, plus. If anyone could help, I'd greatly appreciate it! Here is just a few trials that I was trying to work out: http://codepen.io/spikeyty/pen/wruIs

Answer

nietonfir picture nietonfir · Jan 1, 2014
p
 |Lorem ipsum, 
 b volutpat. 
 |Ut wisi enim ad minim veniam.

This gets rendered as "Lorem ipsum, volutpat. Ut wisi enim ad minim veniam." (see your updated codepen).

Source: https://groups.google.com/forum/#!topic/slim-template/h8fYkG5lj9k