Class: Olivander::Components::MenuItemComponent

Inherits:
ViewComponent::Base
  • Object
show all
Defined in:
app/components/olivander/components/menu_item_component.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(menu_item) ⇒ MenuItemComponent

Returns a new instance of MenuItemComponent.



6
7
8
9
# File 'app/components/olivander/components/menu_item_component.rb', line 6

def initialize(menu_item)
  super
  @menu_item = menu_item
end

Instance Attribute Details

Returns the value of attribute menu_item.



4
5
6
# File 'app/components/olivander/components/menu_item_component.rb', line 4

def menu_item
  @menu_item
end