Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVASCRIPT

_40 0 _55 null _65 0 _72 null react native fetch

//This error occures when you try to print a non resolved promise
// Example the following code while lead to the error
const res = await fetch('some_url/');
console.log(res.json());

// Correct way
const res = await fetch('some_url/');
const json = await res.json();
console.log(json);
 
PREVIOUS NEXT
Tagged: #null #null #react #native #fetch
ADD COMMENT
Topic
Name
7+1 =