When I am trying to authenticate client using Javascript SDK I am getting the above ReferenceError: XMLHttpRequest is not defined. I can see the error is coming from nakama-js package. Can anyone please help? Given below from where the error coming from .
/home/ashik/nakama-prac-1/node_modules/@heroiclabs/nakama-js/dist/nakama-js.cjs.js:544
const descriptor = Object.getOwnPropertyDescriptor(XMLHttpRequest.prototype, "withCredentials");
^
ReferenceError: XMLHttpRequest is not defined
I can see the error is coming from nakama-js.cjs.js file from it’s 544th line. Can any one please help?