Class: Lilac::CLI::SFC::Component
- Inherits:
-
Struct
- Object
- Struct
- Lilac::CLI::SFC::Component
- Defined in:
- lib/lilac/cli/build/sfc.rb
Overview
path is the source file path (or nil for in-memory parses).
templates is an Array, script is a single concatenated
String of all Ruby blocks joined by a newline.
Instance Attribute Summary collapse
-
#path ⇒ Object
Returns the value of attribute path.
-
#script ⇒ Object
Returns the value of attribute script.
-
#templates ⇒ Object
Returns the value of attribute templates.
Instance Method Summary collapse
Instance Attribute Details
#path ⇒ Object
Returns the value of attribute path
31 32 33 |
# File 'lib/lilac/cli/build/sfc.rb', line 31 def path @path end |
#script ⇒ Object
Returns the value of attribute script
31 32 33 |
# File 'lib/lilac/cli/build/sfc.rb', line 31 def script @script end |
#templates ⇒ Object
Returns the value of attribute templates
31 32 33 |
# File 'lib/lilac/cli/build/sfc.rb', line 31 def templates @templates end |
Instance Method Details
#default_templates ⇒ Object
32 33 34 |
# File 'lib/lilac/cli/build/sfc.rb', line 32 def default_templates templates.select { |t| t.name.nil? } end |
#named_templates ⇒ Object
36 37 38 |
# File 'lib/lilac/cli/build/sfc.rb', line 36 def named_templates templates.reject { |t| t.name.nil? } end |