-
Notifications
You must be signed in to change notification settings - Fork 29
/
index.js
23 lines (20 loc) · 929 Bytes
/
index.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
const firebase = require('firebase')
// -- // -- // -- // Firebase Config // -- // -- // -- //
const config = {
apiKey: 'AIzaSyBzz-Wq2dzMgM7E8cdSYnYoX5fbVUT-XQo',
authDomain: 'firebones-6bc2a.firebaseapp.com',
databaseURL: 'https://firebones-6bc2a.firebaseio.com',
projectId: 'firebones-6bc2a',
storageBucket: 'firebones-6bc2a.appspot.com',
messagingSenderId: '1030378391678'
}
// -- // -- // -- // -- // -- // -- // -- // -- // -- //
// Initialize the app, but make sure to do it only once.
// (We need this for the tests. The test runner busts the require
// cache when in watch mode; this will cause us to evaluate this
// file multiple times. Without this protection, we would try to
// initialize the app again, which causes Firebase to throw.
//
// This is why global state makes a sad panda.)
firebase.__bonesApp || (firebase.__bonesApp = firebase.initializeApp(config))
module.exports = firebase