reactjs - Requiring 'fetch' is returning an empty object in a React-Native app -


i'm working on second react-native application. had required fetch so:

var fetch = require('fetch'); 

i never installed npm, available default. started new react-native project (after updating react native cli) , when require fetch in same fashion , try call fetch method app crashes , error says

object not function(evaluating 'fetch(api_url, fetchobject)') 

when console out fetch with

console.log(fetch); 

i get

{} 

any suggestions?

alright, looks don't event have require fetch more. it's available globally.


Comments

Popular posts from this blog

c++ - Difference between pre and post decrement in recursive function argument -

c# - Retrieve google contact -

javascript - How to insert selected radio button value into table cell -