Class: Condenser::EjxTransformer
- Inherits:
-
NodeProcessor
- Object
- NodeProcessor
- Condenser::EjxTransformer
- Defined in:
- lib/condenser/transformers/ejx.rb
Instance Attribute Summary collapse
-
#options ⇒ Object
Returns the value of attribute options.
Class Method Summary collapse
Instance Method Summary collapse
- #call(environment, input) ⇒ Object
-
#initialize(options = {}) ⇒ EjxTransformer
constructor
A new instance of EjxTransformer.
Constructor Details
#initialize(options = {}) ⇒ EjxTransformer
Returns a new instance of EjxTransformer.
5 6 7 |
# File 'lib/condenser/transformers/ejx.rb', line 5 def initialize( = {}) = end |
Instance Attribute Details
#options ⇒ Object
Returns the value of attribute options.
3 4 5 |
# File 'lib/condenser/transformers/ejx.rb', line 3 def end |
Class Method Details
.call(environment, input) ⇒ Object
17 18 19 |
# File 'lib/condenser/transformers/ejx.rb', line 17 def self.call(environment, input) new.call(environment, input) end |
.setup(environment) ⇒ Object
9 10 11 12 13 14 15 |
# File 'lib/condenser/transformers/ejx.rb', line 9 def self.setup(environment) require 'ejx' unless defined?(::EJX) if !environment.path.include?(EJX::ASSET_DIR) environment.append_path(EJX::ASSET_DIR) end end |
Instance Method Details
#call(environment, input) ⇒ Object
21 22 23 |
# File 'lib/condenser/transformers/ejx.rb', line 21 def call(environment, input) input[:source] = EJX::Template.new(input[:source], ).to_module end |