Sha256: 0366942302dcf8c87ba024c4b89bfec3d5a9c01f67f067a87793c76fbc302f76
Contents?: true
Size: 845 Bytes
Versions: 26
Compression:
Stored size: 845 Bytes
Contents
require 'hanami/assets/compressors/javascript' require_relative './jsmin' module Hanami module Assets module Compressors # Builtin compressor for stylesheet # # This is a port of jsmin # Copyright (c) 2002 Douglas Crockford (www.crockford.com) # # This Ruby port was implemented by Ryan Grove (@rgrove) as work for # <tt>jsmin</tt> gem. # # Copyright (c) 2008-2012 Ryan Grove # # @since 0.1.0 # @api private # # @see https://github.com/sbecker/asset_packager class BuiltinJavascript < Javascript def initialize @compressor = JSMin end # @since 0.1.0 # @api private def compress(filename) compressor.minify( read(filename) ) end end end end end
Version data entries
26 entries across 26 versions & 1 rubygems