Sha256: 1edffbd76312cade6c63ac7641709cd71b4ab544b4de4a227a20e82dc8c2c944

Contents?: true

Size: 284 Bytes

Versions: 3

Compression:

Stored size: 284 Bytes

Contents

class HomeResource < Webmachine::Resource
  include Webmachine::ActionView::Resource

  def to_html
    @home = HomeResource.home_instance
    render
  end

  def self.home_instance
    Struct.new(:id, :name).new.tap do |h|
      h.id = 1
      h.name = "some name"
    end
  end
end

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
webmachine-actionview-0.0.3 spec/dummy/resources/home_resource.rb
webmachine-actionview-0.0.2 spec/dummy/resources/home_resource.rb
webmachine-actionview-0.0.1 spec/dummy/resources/home_resource.rb