react-native-eventsource icon indicating copy to clipboard operation
react-native-eventsource copied to clipboard

"data" property should be used, not "message"

Open andrey-skl opened this issue 7 years ago • 1 comments

If server sent event contains "data" property, it is ignored, but "message" used instead: https://github.com/JonnyBGod/react-native-eventsource/blob/master/src/EventSource.js#L58

var event = new EventSourceEvent(ev.type, {
          data: ev.message
        });

andrey-skl avatar Apr 07 '17 18:04 andrey-skl

Looks like it is fixed in @USFT fork https://github.com/USFT/react-native-eventsource/commit/b716648472ee9782f01a67e3e298f9a630149a29

andrey-skl avatar Apr 07 '17 18:04 andrey-skl