{"action":"opened","issue":{"url":"https://api.github.com/repos/bfred-it/object-fit-images/issues/104","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/104/labels{/name}","comments_url":"https://api.github.com/repos/bfred-it/object-fit-images/issues/104/comments","events_url":"https://api.github.com/repos/bfred-it/object-fit-images/issues/104/events","html_url":"https://github.com/bfred-it/object-fit-images/issues/104","id":295821650,"number":104,"title":"Assignment to read-only properties is not allowed in strict mode","user":{"login":"OClyde","id":22261881,"avatar_url":"https://avatars1.githubusercontent.com/u/22261881?v=4","gravatar_id":"","url":"https://api.github.com/users/OClyde","html_url":"https://github.com/OClyde","followers_url":"https://api.github.com/users/OClyde/followers","following_url":"https://api.github.com/users/OClyde/following{/other_user}","gists_url":"https://api.github.com/users/OClyde/gists{/gist_id}","starred_url":"https://api.github.com/users/OClyde/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/OClyde/subscriptions","organizations_url":"https://api.github.com/users/OClyde/orgs","repos_url":"https://api.github.com/users/OClyde/repos","events_url":"https://api.github.com/users/OClyde/events{/privacy}","received_events_url":"https://api.github.com/users/OClyde/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":0,"created_at":"2018-02-09T10:23:34Z","updated_at":"2018-02-09T10:23:34Z","closed_at":null,"author_association":"NONE","body":"When importing this script to my code using the ES6 import notation or when including it as an external script in Angular 5's scripts section, the error mentioned in this issue here still persists: #100 \r\n\r\n`Assignment to read-only properties is not allowed in strict mode`\r\n\r\nTherefore this is currently not WebPack compliant and causes an error in our Angular application.\r\n\r\nI tried the other way of including the script itself in our assets and referencing this in the head of our index.html, which is not causing any error though. \r\n\r\nSpecifically, IE is complaining about those reassignments:\r\n\r\n```\r\nif (!supportsObjectPosition) {\r\n\tHTMLImageElement.prototype.getAttribute = function (name) {\r\n\t\treturn nativeGetAttribute.call(getOfiImageMaybe(this, name), name);\r\n\t};\r\n\r\n\tHTMLImageElement.prototype.setAttribute = function (name, value) {\r\n\t\treturn nativeSetAttribute.call(getOfiImageMaybe(this, name), name, String(value));\r\n\t};\r\n}\r\n``` \r\n\r\nWill try to prepare a sample project to make this reproducible as soon as possible, nevertheless wanted to report this already."}}
{"actor":{"display_login":"OClyde"}}