jgarber / redcloth

RedCloth is a Ruby library for converting Textile into HTML.
Other
445 stars 102 forks source link

Any way to only parse certain tags? #65

Open sean-yeoh opened 3 years ago

sean-yeoh commented 3 years ago

Hi, is there any way to only parse certain tags, for example if I want to only parse bc..:

Given an input string: text = "h5. My Header\r\n\r\nbc.. Hello world\r\n\r\np. Bye world"

I want to get an output like: RedCloth.new(text).to_html #=> "h5. My Header\r\n\r\n<pre><code>Hello world</code></pre>\r\n\r\nBye world"

GregThoma commented 6 months ago

Nor really

GregThoma commented 6 months ago

p>The sun is reportedly hot,1 just like freshly baked potatoes.1 Ice is cold.2

  1. a b Ouch.
  2. a Brrr.

RedCloth 4.3.4