Spaces:
Paused
Paused
| import { initializeApp, getApps, getApp } from "firebase/app"; | |
| import { getAuth, GoogleAuthProvider } from "firebase/auth"; | |
| import { getFirestore } from "firebase/firestore"; | |
| // Your web app's Firebase configuration | |
| const firebaseConfig = { | |
| apiKey: "AIzaSyApTrpWfOUyrlVx1YMrfqwToz48RSPB41A", | |
| authDomain: "scrapi-7a8d0.firebaseapp.com", | |
| projectId: "scrapi-7a8d0", | |
| storageBucket: "scrapi-7a8d0.firebasestorage.app", | |
| messagingSenderId: "491054539000", | |
| appId: "1:491054539000:web:0d10030114fee51a511b0d" | |
| }; | |
| // Initialize Firebase | |
| // Uses getApps() to check if the app is already initialized (prevents errors in Next.js dev mode) | |
| const app = !getApps().length ? initializeApp(firebaseConfig) : getApp(); | |
| // Initialize services | |
| export const auth = getAuth(app); | |
| export const googleProvider = new GoogleAuthProvider(); | |
| export const db = getFirestore(app); // Included in case your app uses Firestore | |
| export default app; | |