Method: SecureHeaders::ViewHelpers#nonced_javascript_tag
- Defined in:
- lib/secure_headers/view_helper.rb
#nonced_javascript_tag(content_or_options = {}, &block) ⇒ Object
Public: create a script tag using the content security policy nonce. Instructs secure_headers to append a nonce to script-src directive.
Returns an html-safe script tag with the nonce attribute.
31 32 33 |
# File 'lib/secure_headers/view_helper.rb', line 31 def nonced_javascript_tag( = {}, &block) nonced_tag(:script, , block) end |