... TODO mention how to configure and use multiple apps
// config/environment.js
var ENV = {
firebase: [{
apiKey: "xyz",
authDomain: "YOUR-FIREBASE-APP.firebaseapp.com",
databaseURL: "https://YOUR-FIREBASE-APP.firebaseio.com",
projectId: "YOUR-FIREBASE-APP",
storageBucket: "YOUR-FIREBASE-APP.appspot.com",
messagingSenderId: "00000000000"
}, {
apiKey: "xyz",
authDomain: "ANOTHER-FIREBASE-APP.firebaseapp.com",
databaseURL: "https://ANOTHER-FIREBASE-APP.firebaseio.com",
projectId: "ANOTHER-FIREBASE-APP",
storageBucket: "ANOTHER-FIREBASE-APP.appspot.com",
messagingSenderId: "00000000000",
name: 'app-for-auth'
}]
}
service:firebase-app
, service:firebase-app-for-auth
import FirebaseSessionStore from 'emberfire/session-stores/firebase';
export default FirebaseSessionStore.extend({
firebaseApp: service('firebase-app-for-auth')
});
... TODO touch on how to register a new service at runtime
... TODO talk about settings and enablePersistence
import FirestoreAdapter from 'emberfire/adapters/firestore';
export default FirestoreAdapter.extend({
enablePersistence: true,
settings: { timestampsInSnapshots: true }
});
... TODO talk about databaseURL
import RealtimeDatabaseAdapter from 'emberfire/adapters/realtime-database';
export default RealtimeDatabaseAdapter.extend({
databaseURL: 'https://SECOND-DATABSE.firebaseio.com'
});