FirebaseError: Firebase: Firebase App named '[DEFAULT]' already exists (app/duplicate-app)., js engine: hermes code example
Example 1: Firebase: Firebase App named '[DEFAULT]' already exists
if (!firebase.apps.length) {
firebase.initializeApp({});
}else {
firebase.app(); // if already initialized, use that one
}
Example 2: Firebase: Firebase App named '[DEFAULT]' already exists
if (!firebase.apps.length) {
firebase.initializeApp({});
}