You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When the event emitter is fired, doing a console log of self in the callback DeviceEventEmitter.addListener('ThreadMessage', (message) => {
seems that onmessage property is always null { onmessage: null, postMessage: [Function: postMessage] }
So the worker self.onmessage is never getting called
Can someone tell if this is true?
The text was updated successfully, but these errors were encountered:
I'm having the same problem. Is there any update ?
My thread code look like that:
import { self } from 'react-native-threads'
console.log(self)
self.onmessage([...])
logs:
05-28 12:51:41.308 18302 18597 I ReactNativeJS: { onmessage: null, postMessage: [Function: postMessage] }
05-28 12:51:41.310 18302 18597 E ReactNativeJS: TypeError: null is not a function (near '...t.self.onmessage...')
When the event emitter is fired, doing a console log of self in the callback
DeviceEventEmitter.addListener('ThreadMessage', (message) => {
seems that onmessage property is always null
{ onmessage: null, postMessage: [Function: postMessage] }
So the worker self.onmessage is never getting called
Can someone tell if this is true?
The text was updated successfully, but these errors were encountered: