https://kotlinlang.org logo
Title
a

andylamax

08/26/2021, 2:59 AM
Uncharted Teritory. While attempting to run my generated javascript code on react native, I am getting
process.nextTick is not a function. (In 'process.nextTick(this._get_messageQueue__1()._processQueue)', 'process.nextTick' is undefined)
at node_modules/@picortex/pi-monitor-client-sdk/pi-monitor-client-sdk.js:13160:17 in <anonymous>
Checking that line number, I see the following generated code
NodeDispatcher.prototype.scheduleQueueProcessing_1 = function () {
    process.nextTick(this._get_messageQueue__1()._processQueue);
  };
I think for some reasons, the library thinks it is running in a node environment. Is there a way I can make this work differently? Any work around?
follow up question. How does the library figure out what runtime it is to create its dispatchers?
a

andylamax

08/26/2021, 3:45 AM
thanks for the quick response