Class: Vueport::Renderer
- Inherits:
-
Object
- Object
- Vueport::Renderer
- Includes:
- ActionView::Helpers::TagHelper
- Defined in:
- lib/vueport/renderer.rb
Constant Summary collapse
- CONTENT_WRAPPER_ID =
'vueport-wrapper'.freeze
- TEMPLATE_ID =
'vueport-template'.freeze
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: '/') ⇒ Renderer
constructor
A new instance of Renderer.
- #render ⇒ Object
Constructor Details
#initialize(content, path: '/') ⇒ Renderer
Returns a new instance of Renderer.
10 11 12 13 |
# File 'lib/vueport/renderer.rb', line 10 def initialize(content, path: '/') self.content = content self.path = path end |
Instance Attribute Details
#content ⇒ Object
Returns the value of attribute content.
8 9 10 |
# File 'lib/vueport/renderer.rb', line 8 def content @content end |
#path ⇒ Object
Returns the value of attribute path.
8 9 10 |
# File 'lib/vueport/renderer.rb', line 8 def path @path end |
Instance Method Details
#render ⇒ Object
15 16 17 |
# File 'lib/vueport/renderer.rb', line 15 def render safe_join [rendered_content, template] end |