Module: Reform::Form::Module::Included

Defined in:
lib/reform/form/module.rb

Instance Method Summary collapse

Instance Method Details

#included(includer) ⇒ Object

Gets imported into your module and will be run when including it.



13
14
15
16
17
18
19
# File 'lib/reform/form/module.rb', line 13

def included(includer)
  super
  # first, replay all declaratives like ::property on includer.
  heritage.(includer) # this normally happens via Heritage::Included.
  # then, include optional accessors.
  includer.send(:include, self::InstanceMethods) if const_defined?(:InstanceMethods)
end