Sha256: 8270ee4961486f353233f5bec98b98b8c1bfb945117c5f1d3b94573a5a6c23b2

Contents?: true

Size: 309 Bytes

Versions: 6

Compression:

Stored size: 309 Bytes

Contents

require "uglifier"
require "cssminify"

module Linner
  class Compressor

    def self.compress(asset)
      if asset.javascript? or asset.template?
        Uglifier.compile asset.content, comments: "none"
      elsif asset.stylesheet?
        CSSminify.new.compress asset.content
      end
    end
  end
end

Version data entries

6 entries across 6 versions & 1 rubygems

Version Path
linner-0.6.3 lib/linner/compressor.rb
linner-0.6.2 lib/linner/compressor.rb
linner-0.6.1 lib/linner/compressor.rb
linner-0.6.0 lib/linner/compressor.rb
linner-0.5.1 lib/linner/compressor.rb
linner-0.5.0 lib/linner/compressor.rb