{"action":"opened","issue":{"url":"https://api.github.com/repos/christianalfoni/flux-react/issues/4","labels_url":"https://api.github.com/repos/christianalfoni/flux-react/issues/4/labels{/name}","comments_url":"https://api.github.com/repos/christianalfoni/flux-react/issues/4/comments","events_url":"https://api.github.com/repos/christianalfoni/flux-react/issues/4/events","html_url":"https://github.com/christianalfoni/flux-react/issues/4","id":60217230,"number":4,"title":"Implement workaround for inconsistent EventEmitter2 module export","user":{"login":"VictorBlomberg","id":883523,"avatar_url":"https://avatars.githubusercontent.com/u/883523?v=3","gravatar_id":"","url":"https://api.github.com/users/VictorBlomberg","html_url":"https://github.com/VictorBlomberg","followers_url":"https://api.github.com/users/VictorBlomberg/followers","following_url":"https://api.github.com/users/VictorBlomberg/following{/other_user}","gists_url":"https://api.github.com/users/VictorBlomberg/gists{/gist_id}","starred_url":"https://api.github.com/users/VictorBlomberg/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/VictorBlomberg/subscriptions","organizations_url":"https://api.github.com/users/VictorBlomberg/orgs","repos_url":"https://api.github.com/users/VictorBlomberg/repos","events_url":"https://api.github.com/users/VictorBlomberg/events{/privacy}","received_events_url":"https://api.github.com/users/VictorBlomberg/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":0,"created_at":"2015-03-07T18:06:27Z","updated_at":"2015-03-07T18:06:27Z","closed_at":null,"body":"Hi,\r\n\r\nflux-ract does currently not work when the EventEmitter2 module is loaded via AMD (see PR https://github.com/asyncly/EventEmitter2/pull/122 and issue https://github.com/asyncly/EventEmitter2/issues/121). Since the EventEmitter2 export favors AMD over CommonJS, and webpack supports both, using flux-react with webpack is not straight forward.\r\n\r\nChanging [action.js:9](https://github.com/christianalfoni/flux-react/blob/master/src/action.js#L9) and [main.js:5](https://github.com/christianalfoni/flux-react/blob/master/src/main.js#L5) from\r\n``var EventEmitter = require('eventemitter2').EventEmitter2;``\r\nto\r\n``var EventEmitter = require('eventemitter2').EventEmitter2 || require('eventemitter2');``\r\nwould solve the issue.\r\n\r\nSince the bug hasn't been fixed for quite a while in EventEmitter2, it would be nice if this workaround could be implemented here.\r\n\r\nVictor Blomberg\r\n"}}