From 6b651d990404239230c821cadfc4ddf8363cb48c Mon Sep 17 00:00:00 2001 From: Laurent Arnoud Date: Wed, 12 Jun 2019 13:57:48 +0200 Subject: Add documentation on actionview asset_path with host and protocol --- actionview/lib/action_view/helpers/asset_url_helper.rb | 2 ++ 1 file changed, 2 insertions(+) (limited to 'actionview') diff --git a/actionview/lib/action_view/helpers/asset_url_helper.rb b/actionview/lib/action_view/helpers/asset_url_helper.rb index cc62783d60..295f945325 100644 --- a/actionview/lib/action_view/helpers/asset_url_helper.rb +++ b/actionview/lib/action_view/helpers/asset_url_helper.rb @@ -133,6 +133,8 @@ module ActionView # which is implemented by sprockets-rails. # # asset_path("application.js") # => "/assets/application-60aa4fdc5cea14baf5400fba1abf4f2a46a5166bad4772b1effe341570f07de9.js" + # asset_path('application.js', host: 'example.com') # => "//example.com/assets/application.js" + # asset_path("application.js", host: 'example.com', protocol: 'https') # => "https://example.com/assets/application.js" # # === Without the asset pipeline (skip_pipeline: true) # -- cgit v1.2.3