Cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Error while using xmlhttprequest module

ANSWERED

while i'm trying to use the module xmlhttprequest i recive the following error : "Unhandled Error: Cannot find module 'xmlhttprequest'".

i'm using this module to recive information based on your actual position from a remote server throught get/post request.

how can i solve this error ?

Best Answer
0 Votes
1 BEST ANSWER

Accepted Solutions

Yes, assuming you're trying to get an AJAX-like response from a server.

Peter McLennan
Gondwana Software

View best answer in original post

Best Answer
0 Votes
4 REPLIES 4

It sounds like you're developing for a web site. Fitbits don't have HTML. Try using fetch().

Peter McLennan
Gondwana Software
Best Answer
0 Votes

You suggest to use fetch() instead of xmlhttprequest ?

Best Answer
0 Votes

Yes, assuming you're trying to get an AJAX-like response from a server.

Peter McLennan
Gondwana Software
Best Answer
0 Votes

Yes, the response will be json file 

Best Answer
0 Votes