{"action":"created","issue":{"url":"https://api.github.com/repos/angular/angular.js/issues/15823","repository_url":"https://api.github.com/repos/angular/angular.js","labels_url":"https://api.github.com/repos/angular/angular.js/issues/15823/labels{/name}","comments_url":"https://api.github.com/repos/angular/angular.js/issues/15823/comments","events_url":"https://api.github.com/repos/angular/angular.js/issues/15823/events","html_url":"https://github.com/angular/angular.js/issues/15823","id":214825026,"number":15823,"title":"Compile out CSP eval code with define plugins","user":{"login":"graingert","id":413772,"avatar_url":"https://avatars0.githubusercontent.com/u/413772?v=3","gravatar_id":"","url":"https://api.github.com/users/graingert","html_url":"https://github.com/graingert","followers_url":"https://api.github.com/users/graingert/followers","following_url":"https://api.github.com/users/graingert/following{/other_user}","gists_url":"https://api.github.com/users/graingert/gists{/gist_id}","starred_url":"https://api.github.com/users/graingert/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/graingert/subscriptions","organizations_url":"https://api.github.com/users/graingert/orgs","repos_url":"https://api.github.com/users/graingert/repos","events_url":"https://api.github.com/users/graingert/events{/privacy}","received_events_url":"https://api.github.com/users/graingert/received_events","type":"User","site_admin":false},"labels":[{"id":69001023,"url":"https://api.github.com/repos/angular/angular.js/labels/component:%20misc%20core","name":"component: misc core","color":"fef2c0","default":false},{"id":19981501,"url":"https://api.github.com/repos/angular/angular.js/labels/needs:%20investigation","name":"needs: investigation","color":"444444","default":false},{"id":83182371,"url":"https://api.github.com/repos/angular/angular.js/labels/severity:%20inconvenient","name":"severity: inconvenient","color":"006b75","default":false},{"id":48406,"url":"https://api.github.com/repos/angular/angular.js/labels/type:%20feature","name":"type: feature","color":"00a606","default":false}],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":{"url":"https://api.github.com/repos/angular/angular.js/milestones/27","html_url":"https://github.com/angular/angular.js/milestone/27","labels_url":"https://api.github.com/repos/angular/angular.js/milestones/27/labels","id":489171,"number":27,"title":"Backlog","description":"Holds the backlog of issues and pull requests that have been triaged.\r\n\r\nBefore assigning items to this milestone they should be labelled, at the very least with the correct \"type\" label (i.e. \"issue\", \"pr\", \"bug\", \"regression\", \"chore\", \"docs\", etc).  Preferably you should also check for duplicate issues/PRs, note CLA status and assign \"complexity\" and \"impact\" labels too.","creator":{"login":"IgorMinar","id":216296,"avatar_url":"https://avatars0.githubusercontent.com/u/216296?v=3","gravatar_id":"","url":"https://api.github.com/users/IgorMinar","html_url":"https://github.com/IgorMinar","followers_url":"https://api.github.com/users/IgorMinar/followers","following_url":"https://api.github.com/users/IgorMinar/following{/other_user}","gists_url":"https://api.github.com/users/IgorMinar/gists{/gist_id}","starred_url":"https://api.github.com/users/IgorMinar/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/IgorMinar/subscriptions","organizations_url":"https://api.github.com/users/IgorMinar/orgs","repos_url":"https://api.github.com/users/IgorMinar/repos","events_url":"https://api.github.com/users/IgorMinar/events{/privacy}","received_events_url":"https://api.github.com/users/IgorMinar/received_events","type":"User","site_admin":false},"open_issues":451,"closed_issues":1589,"state":"open","created_at":"2013-11-18T23:30:35Z","updated_at":"2017-03-20T17:06:04Z","due_on":null,"closed_at":null},"comments":1,"created_at":"2017-03-16T20:14:15Z","updated_at":"2017-03-20T19:24:33Z","closed_at":null,"body":"***Note*: for support questions, please use one of these channels: https://github.com/angular/angular.js/blob/master/CONTRIBUTING.md#question. This repository's issues are reserved for feature requests and bug reports.**\r\n\r\n**Do you want to request a *feature* or report a *bug*?**\r\nFeature\r\n\r\n\r\n**What is the current behavior?**\r\nYou have to use ngCsp, and the bundle is bigger than it needs to be.\r\n\r\n\r\n**If the current behavior is a bug, please provide the steps to reproduce and if possible a minimal demo of the problem via https://plnkr.co or similar (template: http://plnkr.co/edit/tpl:yBpEi4).**\r\n\r\n\r\n\r\n**What is the expected behavior?**\r\nuse webpack define plugin (or UglifyJS or closure) to define a variable ANGULAR_CSP that enables or disables code paths that rely on an insecure or missing CSP.\r\n\r\n\r\n**What is the motivation / use case for changing the behavior?**\r\nI don't want to change all my templates, when I could configure it in one place in my build config.\r\nI also want to strip out any code that even tries to use eval, because I won't need it.\r\n\r\n**Which versions of AngularJS, and which browser / OS are affected by this issue? Did this work in previous versions of AngularJS? Please also test with the latest stable and snapshot (https://code.angularjs.org/snapshot/) versions.**\r\n\r\n\r\n\r\n**Other information (e.g. stacktraces, related issues, suggestions how to fix)**\r\nany code that uses CSP should do:\r\n```\r\nif (typeof ANGULAR_CSP !== 'undefined') {\r\n    ...\r\n}\r\n```\r\nso that optimizing compilers can wipe it out."},"comment":{"url":"https://api.github.com/repos/angular/angular.js/issues/comments/287870167","html_url":"https://github.com/angular/angular.js/issues/15823#issuecomment-287870167","issue_url":"https://api.github.com/repos/angular/angular.js/issues/15823","id":287870167,"user":{"login":"petebacondarwin","id":15655,"avatar_url":"https://avatars3.githubusercontent.com/u/15655?v=3","gravatar_id":"","url":"https://api.github.com/users/petebacondarwin","html_url":"https://github.com/petebacondarwin","followers_url":"https://api.github.com/users/petebacondarwin/followers","following_url":"https://api.github.com/users/petebacondarwin/following{/other_user}","gists_url":"https://api.github.com/users/petebacondarwin/gists{/gist_id}","starred_url":"https://api.github.com/users/petebacondarwin/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/petebacondarwin/subscriptions","organizations_url":"https://api.github.com/users/petebacondarwin/orgs","repos_url":"https://api.github.com/users/petebacondarwin/repos","events_url":"https://api.github.com/users/petebacondarwin/events{/privacy}","received_events_url":"https://api.github.com/users/petebacondarwin/received_events","type":"User","site_admin":false},"created_at":"2017-03-20T19:24:33Z","updated_at":"2017-03-20T19:24:33Z","body":"I would like to see the actual difference in size from doing this before making a decision.\r\nMoreover there are other switches that could trigger different modules to be generated.\r\nSo it could cause an explosion of complexity in our builds."}}
{"actor":{"display_login":"petebacondarwin"}}