I am displaying list of photos fetching from firebase database as in React-Native App in Expo, in photoList.js file,
contents of package.json
are
{
"main": "node_modules/expo/AppEntry.js",
"scripts": {
"start": "expo start",
"android": "expo start --android",
"ios": "expo start --ios",
"eject": "expo eject"
},
"dependencies": {
"expo": "^32.0.0",
"firebase": "^5.9.0",
"react": "16.5.0",
"react-native": "https://github.com/expo/react-native/archive/sdk-32.0.0.tar.gz",
"react-navigation": "^3.4.0"
},
"devDependencies": {
"babel-preset-expo": "^5.0.0"
},
"private": true
}
according to its one solution, without downgrading firebase to 5.0.3
, by changing to @firebase/app
, didn’t work.
import firebase from "@firebase/app";
import "@firebase/database";
import "@firebase/storage";
import "@firebase/auth";
my project-repo on GitHub.
How can I render a list of photos, without downgrading to older versions? because I think downgrading to older versions is not a future-proof and longtime solution.
also, I didn’t try this solution, ,
because I am exporting firebase, auth, database, storage to othre components as,
export const f = firebase;
export const database = firebase.database();
export const auth = firebase.auth();
export const storage = firebase.storage();
How can I solve it?
Edit 1:
I tried downgrading versions to 5.0.3
, 4.9.1
, but the error still occurs