Module: React::Component::DslInstanceMethods

Defined in:
lib/react/component/dsl_instance_methods.rb

Instance Method Summary collapse

Instance Method Details

#childrenObject



6
7
8
# File 'lib/react/component/dsl_instance_methods.rb', line 6

def children
  Children.new(`#{@native}.props.children`)
end

#paramsObject



10
11
12
# File 'lib/react/component/dsl_instance_methods.rb', line 10

def params
  @params ||= self.class.props_wrapper.new(self)
end

#propsObject



14
15
16
# File 'lib/react/component/dsl_instance_methods.rb', line 14

def props
  Hash.new(`#{@native}.props`)
end

#refsObject



18
19
20
# File 'lib/react/component/dsl_instance_methods.rb', line 18

def refs
  Hash.new(`#{@native}.refs`)
end