{"action":"created","issue":{"url":"https://api.github.com/repos/Blank101/haxe-dom/issues/31","labels_url":"https://api.github.com/repos/Blank101/haxe-dom/issues/31/labels{/name}","comments_url":"https://api.github.com/repos/Blank101/haxe-dom/issues/31/comments","events_url":"https://api.github.com/repos/Blank101/haxe-dom/issues/31/events","html_url":"https://github.com/Blank101/haxe-dom/issues/31","id":115472265,"number":31,"title":"IE EventTarget undefined - problem and workaround","user":{"login":"cambiata","id":217074,"avatar_url":"https://avatars.githubusercontent.com/u/217074?v=3","gravatar_id":"","url":"https://api.github.com/users/cambiata","html_url":"https://github.com/cambiata","followers_url":"https://api.github.com/users/cambiata/followers","following_url":"https://api.github.com/users/cambiata/following{/other_user}","gists_url":"https://api.github.com/users/cambiata/gists{/gist_id}","starred_url":"https://api.github.com/users/cambiata/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/cambiata/subscriptions","organizations_url":"https://api.github.com/users/cambiata/orgs","repos_url":"https://api.github.com/users/cambiata/repos","events_url":"https://api.github.com/users/cambiata/events{/privacy}","received_events_url":"https://api.github.com/users/cambiata/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":1,"created_at":"2015-11-06T09:49:24Z","updated_at":"2015-11-06T21:48:25Z","closed_at":null,"body":"Hxdom doesn't work for me out of the box in Internet Explorer 11 (and probably not in earlier versions) - I get an \"'EventTarget' is undefined\" error, and that halts the whole thing as  hxdom_VirtualNode.__super__ = EventTarget.\r\n\r\nMy workaround is to mock the EventTarget by loading the js code below before the hxdom script.\r\nMaybe there are other solutions to this, but I just wanted to share if someone else faces  the same problem. \r\n\r\nThanks a lot for this awesome library, Sam!\r\n/ Jonas\r\n\r\n```\r\n// eventtarget.js\r\n\r\nif (EventTarget == undefined) {\r\n\r\n\t//alert('EventTarget is undefined');\r\n\r\n\tfunction EventTarget() {\r\n\t  var eventTarget = document.createDocumentFragment();\r\n\t  function delegate(method) {\r\n\t    this[method] = eventTarget[method].bind(eventTarget);\r\n\t  }\r\n\t  [\r\n\t    \"addEventListener\",\r\n\t    \"dispatchEvent\",\r\n\t    \"removeEventListener\"\r\n\t  ].forEach(delegate, this);\r\n\t}\r\n}\r\n\r\n```\r\n\r\n"},"comment":{"url":"https://api.github.com/repos/Blank101/haxe-dom/issues/comments/154551808","html_url":"https://github.com/Blank101/haxe-dom/issues/31#issuecomment-154551808","issue_url":"https://api.github.com/repos/Blank101/haxe-dom/issues/31","id":154551808,"user":{"login":"Blank101","id":588921,"avatar_url":"https://avatars.githubusercontent.com/u/588921?v=3","gravatar_id":"","url":"https://api.github.com/users/Blank101","html_url":"https://github.com/Blank101","followers_url":"https://api.github.com/users/Blank101/followers","following_url":"https://api.github.com/users/Blank101/following{/other_user}","gists_url":"https://api.github.com/users/Blank101/gists{/gist_id}","starred_url":"https://api.github.com/users/Blank101/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Blank101/subscriptions","organizations_url":"https://api.github.com/users/Blank101/orgs","repos_url":"https://api.github.com/users/Blank101/repos","events_url":"https://api.github.com/users/Blank101/events{/privacy}","received_events_url":"https://api.github.com/users/Blank101/received_events","type":"User","site_admin":false},"created_at":"2015-11-06T21:48:25Z","updated_at":"2015-11-06T21:48:25Z","body":"Ah thanks for this. I should have that mentioned somewhere. I'll leave this task open to remind me. I had a problem with the span html element as well. I just include this code:\r\n\r\n\twindow.EventTarget || (window.EventTarget = function () {}); window.HTMLSpanElement || (window.HTMLSpanElement = function () {});"}}