Project

dom_render

0.0
No commit activity in last 3 years
No release in over 3 years
Designed to render HTML
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
 Dependencies

Runtime

~> 1.5, >= 1.5.6
 Project Readme

Introducing the dom_render gem

require 'dom_render'


class Html < DomRender

  def p(x)
    render_all x
  end

  def b(x)
    [:bold_on, render_all(x), :bold_off]
  end

end



s =<<EOF
<p>this is test of the 
  <b>bold</b>
 text
</p>
EOF

a = Html.new(s).to_a
=> ["this is test of the ", [:bold_on, ["bold"], :bold_off], " text"]

Resources

dom_render domrender dom html engine