Class: Arbre::Form::Config::Component

Inherits:
Object
  • Object
show all
Defined in:
lib/arbre/form/config.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(tag:, type: nil, formatter: proc { |val| val }) ⇒ Component

Returns a new instance of Component.



13
14
15
16
17
# File 'lib/arbre/form/config.rb', line 13

def initialize(tag:, type: nil, formatter: proc { |val| val })
  @tag = tag
  @type = type
  @formatter = formatter
end

Instance Attribute Details

#formatterObject

Returns the value of attribute formatter.



11
12
13
# File 'lib/arbre/form/config.rb', line 11

def formatter
  @formatter
end

#tagObject

Returns the value of attribute tag.



11
12
13
# File 'lib/arbre/form/config.rb', line 11

def tag
  @tag
end

#typeObject

Returns the value of attribute type.



11
12
13
# File 'lib/arbre/form/config.rb', line 11

def type
  @type
end