Class: React::Component::History
- Inherits:
-
Object
- Object
- React::Component::History
show all
- Includes:
- Native::Wrapper
- Defined in:
- lib/react/component/history.rb
Instance Method Summary
collapse
Dynamic Method Handling
This class handles dynamic methods through the method_missing method
#method_missing(prop, *args, &block) ⇒ Object
17
18
19
|
# File 'lib/react/component/history.rb', line 17
def method_missing(prop, *args, &block)
@native.JS[:params].JS[prop]
end
|
Instance Method Details
#_react_component_hitory_original_method_missing ⇒ Object
15
|
# File 'lib/react/component/history.rb', line 15
alias _react_component_hitory_original_method_missing method_missing
|
#location ⇒ Object
21
22
23
24
25
26
27
28
29
|
# File 'lib/react/component/history.rb', line 21
def location
return @location if @location
return nil unless @native.JS[:props].JS[:location]
if @native.JS[:props].JS[:location].JS[:pathname]
@location = React::Component::Location.new(@native.JS[:props].JS[:location])
else
@native.JS[:props].JS[:location]
end
end
|
#to_n ⇒ Object
31
32
33
|
# File 'lib/react/component/history.rb', line 31
def to_n
@native
end
|