{"action":"created","issue":{"url":"https://api.github.com/repos/bfred-it/object-fit-images/issues/36","repository_url":"https://api.github.com/repos/bfred-it/object-fit-images","labels_url":"https://api.github.com/repos/bfred-it/object-fit-images/issues/36/labels{/name}","comments_url":"https://api.github.com/repos/bfred-it/object-fit-images/issues/36/comments","events_url":"https://api.github.com/repos/bfred-it/object-fit-images/issues/36/events","html_url":"https://github.com/bfred-it/object-fit-images/issues/36","id":176759591,"number":36,"title":"Unable to include into existing uglified/minified code.","user":{"login":"patricknelson","id":4269377,"avatar_url":"https://avatars.githubusercontent.com/u/4269377?v=3","gravatar_id":"","url":"https://api.github.com/users/patricknelson","html_url":"https://github.com/patricknelson","followers_url":"https://api.github.com/users/patricknelson/followers","following_url":"https://api.github.com/users/patricknelson/following{/other_user}","gists_url":"https://api.github.com/users/patricknelson/gists{/gist_id}","starred_url":"https://api.github.com/users/patricknelson/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/patricknelson/subscriptions","organizations_url":"https://api.github.com/users/patricknelson/orgs","repos_url":"https://api.github.com/users/patricknelson/repos","events_url":"https://api.github.com/users/patricknelson/events{/privacy}","received_events_url":"https://api.github.com/users/patricknelson/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":3,"created_at":"2016-09-13T21:50:08Z","updated_at":"2016-10-21T12:24:39Z","closed_at":"2016-09-14T04:29:02Z","body":"I found a workaround for this (just to take the edge off after seeing that subject :+1:). Basically my workflow is this:\r\n\r\n* Grunt to compile SASS + JS files\r\n* JS is minified/uglified (etc) into two main files: `head.js` and `foot.js`\r\n\r\nMy main issue here is that I have one main processor for `head.js` which manually selects a few files here and there and then concatenates/uglifies a few more and so on, until I have my final header file. I noticed that when I included the existing `ofi.browser.js` file, it failed with JS errors in the targeted browser (IE).  This is because IE couldn't handle this file being mangled 2x's.\r\n\r\nHowever, if I disabled the mangling happening by `uglify` here (https://github.com/bfred-it/npm-bundler/blob/master/index.js#L60) I ended up with a file I could simply add to my existing project without adding another completely separate step in my already complex workflow just to accommodate one file which cannot handle being uglified 2x's.\r\n\r\nMy fix would likely be:\r\n\r\n1. Add the option to disable `uglify` in  `bfred-npm-bundler`\r\n2. Use this new option in `object-fit-images` and include a command to build a second version of the file which is not minified (or some workflow which first generates a regular version, then a second uglified version in one command).\r\n\r\nWhat do you think? This would work well for me in the long term since then I can get updates to this module without much hassle (i.e. manually editing your custom packager to disable uglify) and still not have a dramatically modified Grunt workflow."},"comment":{"url":"https://api.github.com/repos/bfred-it/object-fit-images/issues/comments/255366008","html_url":"https://github.com/bfred-it/object-fit-images/issues/36#issuecomment-255366008","issue_url":"https://api.github.com/repos/bfred-it/object-fit-images/issues/36","id":255366008,"user":{"login":"bfred-it","id":1402241,"avatar_url":"https://avatars.githubusercontent.com/u/1402241?v=3","gravatar_id":"","url":"https://api.github.com/users/bfred-it","html_url":"https://github.com/bfred-it","followers_url":"https://api.github.com/users/bfred-it/followers","following_url":"https://api.github.com/users/bfred-it/following{/other_user}","gists_url":"https://api.github.com/users/bfred-it/gists{/gist_id}","starred_url":"https://api.github.com/users/bfred-it/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/bfred-it/subscriptions","organizations_url":"https://api.github.com/users/bfred-it/orgs","repos_url":"https://api.github.com/users/bfred-it/repos","events_url":"https://api.github.com/users/bfred-it/events{/privacy}","received_events_url":"https://api.github.com/users/bfred-it/received_events","type":"User","site_admin":false},"created_at":"2016-10-21T12:24:38Z","updated_at":"2016-10-21T12:24:38Z","body":"This issue was fixed in UglifyJS 2.7.0"}}
{"actor":{"display_login":"bfred-it"}}