Event Listeners Not Triggering in Expo Environment
I'm facing an issue where event listeners for 'message' and 'error' aren't being invoked when using the library within an Expo app, despite the EventSource connection being established.
Environment:
Expo SDK Version: 51.0.0 Platform: Android, iOS
Expected Behavior: The 'message' event listener should be invoked when the server sends an event, and the 'error' event listener should be triggered in case of connection errors.
I kindly request your assistance in resolving this issue. Please let me know if you require further information or have any suggestions.
It's possible that Expo's dev tools interceptor is blocking the event-stream. See https://github.com/expo/expo/issues/27526
Here is a possible fix: https://github.com/MartinHarkins/expo-sse-patch
@EmilJunker The Same issue is there with React-Native-CLI as well.
It was working around a week ago, but suddenly it is not working.
"react": "^18.2.0",
"react-native": "^0.73.9",
"react-native-sse": "^1.2.1"
And in android it is not triggering due to that using workaround with
"react-native-oksse": "^0.2.0",
Please someone help around on this issue fix
Same issue here in Expo 51, we receive the open event but no others.