Method: ActionWidget::Base#initialize
- Defined in:
- lib/action_widget/base.rb
#initialize(view, attributes = {}) ⇒ Base
Returns a new instance of Base.
13 14 15 16 17 18 19 |
# File 'lib/action_widget/base.rb', line 13 def initialize(view, attributes = {}) properties = self.class.properties attributes, = attributes.partition { |name, value| properties.key?(name) } = Hash[] super(view, Hash[attributes]) end |