Sha256: 94b676b5700e6fbc64c949e4433144f40b213d7f8e5ec67ad59f427ac457c08b

Contents?: true

Size: 393 Bytes

Versions: 12

Compression:

Stored size: 393 Bytes

Contents

module Locomotive  
  module Liquid    
    module Drops    
      class Javascripts < ::Liquid::Drop
  
        def initialize(site)
          @site = site
        end
  
        def before_method(meth)
          asset = @site.theme_assets.where(:content_type => 'javascript', :slug => meth.to_s).first
          !asset.nil? ? asset.source.url : nil
        end
  
      end
    end
  end
end

Version data entries

12 entries across 12 versions & 1 rubygems

Version Path
locomotive_cms-0.0.3.3 lib/locomotive/liquid/drops/javascripts.rb
locomotive_cms-0.0.3.1 lib/locomotive/liquid/drops/javascripts.rb
locomotive_cms-0.0.2.9 lib/locomotive/liquid/drops/javascripts.rb
locomotive_cms-0.0.2.8 lib/locomotive/liquid/drops/javascripts.rb
locomotive_cms-0.0.2.7 lib/locomotive/liquid/drops/javascripts.rb
locomotive_cms-0.0.2.6 lib/locomotive/liquid/drops/javascripts.rb
locomotive_cms-0.0.2.5 lib/locomotive/liquid/drops/javascripts.rb
locomotive_cms-0.0.2.4 lib/locomotive/liquid/drops/javascripts.rb
locomotive_cms-0.0.2.3 lib/locomotive/liquid/drops/javascripts.rb
locomotive_cms-0.0.2.2 lib/locomotive/liquid/drops/javascripts.rb
locomotive_cms-0.0.2.1 lib/locomotive/liquid/drops/javascripts.rb
locomotive_cms-0.0.2 lib/locomotive/liquid/drops/javascripts.rb