Skip to content

Instantly share code, notes, and snippets.

@Jarmahent
Last active June 7, 2019 03:06
Show Gist options
  • Save Jarmahent/8261dd855fcd3a2a2b35a973c6ef5545 to your computer and use it in GitHub Desktop.
Save Jarmahent/8261dd855fcd3a2a2b35a973c6ef5545 to your computer and use it in GitHub Desktop.
// Import only the components that we are going to use for security reasons
import * as firebase from 'firebase/app';
import 'firebase/auth';
import 'firebase/database';
// Export your app because you will be using it in other files
export const app = firebase.initializeApp({
apiKey: "",
authDomain: "",
databaseURL: "",
projectId: "",
storageBucket: "",
messagingSenderId: "",
appId: ""
});
// Export the database instance because we will be writing and reading from it
export const db = app.database();
// Export a database reference called page_data and admin_user
export const page_data = db.ref('page_data');
export const admin_user = db.ref('admin_user');
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment