Module: AssetTrip::Helper
- Defined in:
- lib/asset_trip/helper.rb
Instance Method Summary collapse
- #javascript_include_asset(*sources) ⇒ Object
- #rewrite_asset_path(source) ⇒ Object
- #stylesheet_link_asset(*sources) ⇒ Object
Instance Method Details
#javascript_include_asset(*sources) ⇒ Object
4 5 6 7 8 |
# File 'lib/asset_trip/helper.rb', line 4 def javascript_include_asset(*sources) _javascripts_for_sources(sources).map do |javascript| javascript_include_tag(javascript) end.join("\n") end |
#rewrite_asset_path(source) ⇒ Object
18 19 20 21 22 23 24 |
# File 'lib/asset_trip/helper.rb', line 18 def rewrite_asset_path(source) if source =~ /assets/ source else super end end |
#stylesheet_link_asset(*sources) ⇒ Object
10 11 12 13 14 15 16 |
# File 'lib/asset_trip/helper.rb', line 10 def stylesheet_link_asset(*sources) = sources. _stylesheets_for_sources(sources).map do |stylesheet| stylesheet_link_tag(stylesheet, ) end.join("\n") end |