Class: Opal::Slim::SlimProcessor
- Inherits:
-
BuilderProcessors::RubyProcessor
- Object
- BuilderProcessors::RubyProcessor
- Opal::Slim::SlimProcessor
- Defined in:
- lib/opal/slim.rb
Instance Method Summary collapse
-
#initialize(*args) ⇒ SlimProcessor
constructor
A new instance of SlimProcessor.
- #prepare(source, path) ⇒ Object
- #requires ⇒ Object
Constructor Details
#initialize(*args) ⇒ SlimProcessor
Returns a new instance of SlimProcessor.
47 48 49 50 |
# File 'lib/opal/slim.rb', line 47 def initialize *args super @source = prepare(@source, @filename) end |
Instance Method Details
#prepare(source, path) ⇒ Object
56 57 58 59 |
# File 'lib/opal/slim.rb', line 56 def prepare source, path slim = ::Opal::Slim.compiled_slim(source) ::Opal::Slim.wrap(slim, path) end |
#requires ⇒ Object
52 53 54 |
# File 'lib/opal/slim.rb', line 52 def requires ['opal-slim', 'erb'] + super end |