Class: Sprockets::Base
- Defined in:
- opal/lib/opal/sprockets/cache_key_fix.rb
Instance Method Summary collapse
Instance Method Details
#cache_key_for(path, options) ⇒ Object
6 7 8 9 10 11 12 13 14 15 |
# File 'opal/lib/opal/sprockets/cache_key_fix.rb', line 6 def cache_key_for(path, ) "#{path}:#{[:bundle] ? '1' : '0'}" processors = attributes_for(path).processors processors_key = processors.map do |p| version = p.respond_to?(:version) ? p.version : '0' "#{p.name}-#{version}" end.join(':') "#{path}:#{[:bundle] ? '1' : '0'}:#{processors_key}" end |