-
Notifications
You must be signed in to change notification settings - Fork 80
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
React Native - warn message sends Can't find variable: TextEncoder #53
Comments
TextEncoder and TextDecoder are needed by this library. Please see the following article for details on how to get poly-fills: |
I am closing this, if it is still unresolved, please open a new issue. |
@kum-deepak this article page is not found :'( |
@kum-deepak |
For react native, please also check https://stomp-js.github.io/workaround/stompjs/rx-stomp/ng2-stompjs/2019/06/10/react-native-null-chopping-issue.html |
that doesn't work for me!!! |
I tried nodejs solution in my react code |
@kum-deepak thanks for the link React Native already supports WebSocket thus we only need to add text-encoder to global TextEncoder, TextDecoder objects: const TextEncodingPolyfill = require('text-encoding');
Object.assign(global, {
TextEncoder: TextEncodingPolyfill.TextEncoder,
TextDecoder: TextEncodingPolyfill.TextDecoder,
}); |
@ufukomer @kum-deepak I'm getting the same |
I do not use React Native myself. Please check https://stomp-js.github.io/guide/stompjs/rx-stomp/ng2-stompjs/pollyfils-for-stompjs-v5.html#in-react-native which is based on information as reported by others. |
@madsams Hey which solution you tried for |
this solved the problem, thank you 😁 |
I am using Stompjs to connect with Apache ActiveMQ and Spring Server but when I run application I receive a console warning message and after I navigate to another Screen with lots of data I receive this error non-stop as if it went to a loop.
Error:
I believe this has to do with the package rather than my code
The text was updated successfully, but these errors were encountered: