Module: AsplesSinatra::Helpers
- Defined in:
- lib/asples_sinatra/helpers.rb
Instance Method Summary collapse
Instance Method Details
#input(name, options = {}) ⇒ Object
3 4 5 6 7 |
# File 'lib/asples_sinatra/helpers.rb', line 3 def input(name, ={}) template_path = File.join(File.dirname(File.(__FILE__)), '/templates/input.haml') tmpl = Tilt.new(template_path) tmpl.render(self, .merge!({field_name: name})) end |