Class: Vueport::NodeClient
- Inherits:
-
Object
- Object
- Vueport::NodeClient
- Defined in:
- lib/vueport/node_client.rb
Instance Attribute Summary collapse
-
#content ⇒ Object
Returns the value of attribute content.
-
#path ⇒ Object
Returns the value of attribute path.
Instance Method Summary collapse
-
#initialize(content, path: '/') ⇒ NodeClient
constructor
A new instance of NodeClient.
- #run! ⇒ Object
Constructor Details
#initialize(content, path: '/') ⇒ NodeClient
Returns a new instance of NodeClient.
7 8 9 10 |
# File 'lib/vueport/node_client.rb', line 7 def initialize(content, path: '/') self.content = content self.path = path end |
Instance Attribute Details
#content ⇒ Object
Returns the value of attribute content.
5 6 7 |
# File 'lib/vueport/node_client.rb', line 5 def content @content end |
#path ⇒ Object
Returns the value of attribute path.
5 6 7 |
# File 'lib/vueport/node_client.rb', line 5 def path @path end |
Instance Method Details
#run! ⇒ Object
12 13 14 |
# File 'lib/vueport/node_client.rb', line 12 def run! render.force_encoding('UTF-8').encode!.html_safe end |