9 lines
311 B
TypeScript
9 lines
311 B
TypeScript
import { getFirestore } from '@firebase/firestore'
|
|
import { initializeApp, getApps, getApp } from 'firebase/app'
|
|
import { FIREBASE_CONFIG } from '../../../common/access'
|
|
|
|
// Initialize Firebase
|
|
export const app = getApps().length ? getApp() : initializeApp(FIREBASE_CONFIG)
|
|
|
|
export const db = getFirestore(app)
|