Sha256: f9c8ddcbb9fdd7512c075d81bb9c8352a42de52f5e385864a1f897f05064c8d4
Contents?: true
Size: 950 Bytes
Versions: 1
Compression:
Stored size: 950 Bytes
Contents
require_relative 'assets' require_relative 'config' require_relative 'middleware' require_relative 'version' require_relative 'preprocessors/css-preprocessor' require_relative 'preprocessors/image-preprocessor' require_relative 'preprocessors/javascript-preprocessor' require_relative 'preprocessors/sass-preprocessor' Pakyow::App.after :configure do config.assets.stores.each_pair do |name, path| Pakyow::Assets.register_path_with_name(path, name) end if config.assets.compile_on_startup Pakyow::App.processor :html do |content| Pakyow::Assets.mixin_fingerprints(content) end Pakyow.logger.debug 'Precompiling assets...' Pakyow::Assets.precompile Pakyow.logger.debug 'Finished precompiling!' end end # make sure this middleware executes first # FIXME: need an api for this on Pakyow::App Pakyow::App.class_variable_get(:@@middleware).unshift(lambda { |builder| builder.use Pakyow::Assets::Middleware })
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
pakyow-assets-0.1.2 | lib/pakyow-assets.rb |