Padrino Pipeline is a gem for Padrino. It provides a unified way to use several different asset management systems.
Add to your Gemfile:
gem 'padrino-pipeline'
These examples examples setup a pipeline with defaulted options(see default options):
module Example
class App < Padrino::Application
register Padrino::Pipeline
configure_assets do |config|
config.pipeline = Padrino::Pipeline::Sprockets
end
end
end
module Example
class App < Padrino::Application
register Padrino::Pipeline
configure_assets do |config|
config.pipeline = Padrino::Pipeline::AssetPack
end
end
end
Certain options can be configured to change the behavior of the pipelines. These options should be used within the configure_assets block.
for example:
module Example
class App < Padrino::Application
register Padrino::Pipeline
configure_assets do |config|
config.pipeline = Padrino::Pipeline::AssetPack
config.css_prefix = '/xyz'
end
end
end
The following options can be set
TODO
module Example
class App < Padrino::Application
register Padrino::Pipeline
configure_assets do |config|
config.pipeline = Padrino::Pipeline::AssetPack
config.packages << [:js, :application, '/assets/javascripts/application.js', ['/assets/javascripts/*.js']]
end
end
end
Will serve /assets/javascripts/application.js as a bundle
TODO