With the help of Tim F., I’m glad to present a new plugin for
writing HTML templates in plain Ruby. You write .mab templates in
app/views/ which contain Builder-like representations of HTML.
As an illustration, here is the scaffold edit.rhtml remade as Markaby:
h1 ‘Editing product’
start_form_tag :action => ‘update’, :id => @product
render :partial => ‘form’
link_to ‘Show’, :action => ‘show’, :id => @product
text " | "
link_to ‘Back’, :action => ‘list’
To install in your Rails app:
Many more examples and caveats can be looked over at the announcement: