{"action":"created","issue":{"url":"https://api.github.com/repos/twitter/secureheaders/issues/242","repository_url":"https://api.github.com/repos/twitter/secureheaders","labels_url":"https://api.github.com/repos/twitter/secureheaders/issues/242/labels{/name}","comments_url":"https://api.github.com/repos/twitter/secureheaders/issues/242/comments","events_url":"https://api.github.com/repos/twitter/secureheaders/issues/242/events","html_url":"https://github.com/twitter/secureheaders/issues/242","id":145772999,"number":242,"title":"Adding a nonce to whitelist the output of Rails' javascript_include_tag helper. ","user":{"login":"dqdinh","id":739938,"avatar_url":"https://avatars.githubusercontent.com/u/739938?v=3","gravatar_id":"","url":"https://api.github.com/users/dqdinh","html_url":"https://github.com/dqdinh","followers_url":"https://api.github.com/users/dqdinh/followers","following_url":"https://api.github.com/users/dqdinh/following{/other_user}","gists_url":"https://api.github.com/users/dqdinh/gists{/gist_id}","starred_url":"https://api.github.com/users/dqdinh/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dqdinh/subscriptions","organizations_url":"https://api.github.com/users/dqdinh/orgs","repos_url":"https://api.github.com/users/dqdinh/repos","events_url":"https://api.github.com/users/dqdinh/events{/privacy}","received_events_url":"https://api.github.com/users/dqdinh/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"milestone":null,"comments":5,"created_at":"2016-04-04T18:54:42Z","updated_at":"2016-04-04T21:32:15Z","closed_at":"2016-04-04T21:32:15Z","body":"The README suggests calling \"... the SecureHeaders.content_security_policy_nonce then set the nonce attributes on the various tags.\" to create and use a nonce. I'm trying to whitelist the output script from Rails' javascript_include_tag helper:\r\n\r\n```<%= javascript_include_tag 'application' , nonce: SecureHeaders.content_security_policy_nonce %>```\r\n\r\nbut I'm getting this error:\r\n\r\n```ActionView::Template::Error (undefined method `content_security_policy_nonce' for SecureHeaders:Module)```\r\n\r\nIs there a way to directly call content_security_policy_nonce to generate and attach a nonce to whitelist  Rails' javascript_include_tag helper?"},"comment":{"url":"https://api.github.com/repos/twitter/secureheaders/issues/comments/205505820","html_url":"https://github.com/twitter/secureheaders/issues/242#issuecomment-205505820","issue_url":"https://api.github.com/repos/twitter/secureheaders/issues/242","id":205505820,"user":{"login":"dqdinh","id":739938,"avatar_url":"https://avatars.githubusercontent.com/u/739938?v=3","gravatar_id":"","url":"https://api.github.com/users/dqdinh","html_url":"https://github.com/dqdinh","followers_url":"https://api.github.com/users/dqdinh/followers","following_url":"https://api.github.com/users/dqdinh/following{/other_user}","gists_url":"https://api.github.com/users/dqdinh/gists{/gist_id}","starred_url":"https://api.github.com/users/dqdinh/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dqdinh/subscriptions","organizations_url":"https://api.github.com/users/dqdinh/orgs","repos_url":"https://api.github.com/users/dqdinh/repos","events_url":"https://api.github.com/users/dqdinh/events{/privacy}","received_events_url":"https://api.github.com/users/dqdinh/received_events","type":"User","site_admin":false},"created_at":"2016-04-04T21:32:15Z","updated_at":"2016-04-04T21:32:15Z","body":"Thanks!"}}