Class: Plate::ParagraphNode
- Defined in:
- lib/plate/nodes.rb,
lib/plate/compiler.rb
Instance Attribute Summary
Attributes inherited from RichNode
#body, #parent, #scripts, #styles
Instance Method Summary collapse
- #compile(compiler, parent = nil) ⇒ Object
-
#initialize(body) ⇒ ParagraphNode
constructor
A new instance of ParagraphNode.
Methods inherited from RichNode
#compile_body, #parent_repeat?, #repeat?
Methods included from Inspector
Constructor Details
#initialize(body) ⇒ ParagraphNode
Returns a new instance of ParagraphNode.
68 69 70 |
# File 'lib/plate/nodes.rb', line 68 def initialize(body) super(body) end |
Instance Method Details
#compile(compiler, parent = nil) ⇒ Object
201 202 203 204 |
# File 'lib/plate/compiler.rb', line 201 def compile(compiler, parent = nil) content, style, script = compile_body(compiler, parent) "<p#{style}#{script}>#{content}</p>" end |