mirror of
https://github.com/kevin-DL/commander_league_web.git
synced 2026-01-13 18:55:30 +00:00
Initial commit from Create Next App
This commit is contained in:
15
utils/auth/initFirebase.js
Normal file
15
utils/auth/initFirebase.js
Normal file
@@ -0,0 +1,15 @@
|
||||
import firebase from 'firebase/app'
|
||||
import 'firebase/auth'
|
||||
|
||||
const config = {
|
||||
apiKey: process.env.NEXT_PUBLIC_FIREBASE_PUBLIC_API_KEY,
|
||||
authDomain: process.env.NEXT_PUBLIC_FIREBASE_AUTH_DOMAIN,
|
||||
databaseURL: process.env.NEXT_PUBLIC_FIREBASE_DATABASE_URL,
|
||||
projectId: process.env.NEXT_PUBLIC_FIREBASE_PROJECT_ID,
|
||||
}
|
||||
|
||||
export default function initFirebase() {
|
||||
if (!firebase.apps.length) {
|
||||
firebase.initializeApp(config)
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user