Sha256: 3328ffc34aed6bfc7bbc4ad7c336d3e35e0eb4e666ac6a73278203097a713128

Contents?: true

Size: 368 Bytes

Versions: 5

Compression:

Stored size: 368 Bytes

Contents

module Trestle
  class Form
    extend ActiveSupport::Autoload

    autoload :Automatic
    autoload :Builder
    autoload :Field
    autoload :Fields
    autoload :Renderer

    attr_reader :block

    def initialize(&block)
      @block = block
    end

    def render(template, instance)
      Renderer.new(template).render_form(instance, &block)
    end
  end
end

Version data entries

5 entries across 5 versions & 1 rubygems

Version Path
trestle-0.8.5 lib/trestle/form.rb
trestle-0.8.4 lib/trestle/form.rb
trestle-0.8.3 lib/trestle/form.rb
trestle-0.8.2 lib/trestle/form.rb
trestle-0.8.0 lib/trestle/form.rb