Class: Paste::Glue
- Inherits:
-
Object
- Object
- Paste::Glue
- Extended by:
- Resolver
- Includes:
- ActiveSupport::Configurable, Cache, ERBRenderer, Resolver
- Defined in:
- lib/paste/glue.rb
Instance Method Summary collapse
-
#initialize ⇒ Glue
constructor
A new instance of Glue.
- #paste(*sources) ⇒ Object
Methods included from Resolver
Methods included from Cache
Methods included from ERBRenderer
Constructor Details
#initialize ⇒ Glue
Returns a new instance of Glue.
12 13 14 |
# File 'lib/paste/glue.rb', line 12 def initialize config.js_load_path << erb_path end |
Instance Method Details
#paste(*sources) ⇒ Object
16 17 18 19 20 21 22 23 24 25 26 27 28 |
# File 'lib/paste/glue.rb', line 16 def paste *sources js_dependencies = [] css_dependencies = [] sources.each do |source| in_order_traversal parser(source), js_dependencies, css_dependencies end { :javascripts => js_dependencies, :stylesheets => css_dependencies } end |