Skip to content

Commit

Permalink
configuring firebase emulator
Browse files Browse the repository at this point in the history
  • Loading branch information
EvelynBunnyDev committed Feb 15, 2024
1 parent e3b7c03 commit b2ebf26
Show file tree
Hide file tree
Showing 4 changed files with 503 additions and 50 deletions.
12 changes: 6 additions & 6 deletions .env.local
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
REACT_APP_FIREBASE_API_KEY=your-api-key
REACT_APP_FIREBASE_AUTH_DOMAIN=your-auth-domain
REACT_APP_FIREBASE_PROJECT_ID=your-project-id
REACT_APP_FIREBASE_STORAGE_BUCKET=your-storage-bucket
REACT_APP_FIREBASE_MESSAGING_SENDER_ID=your-messaging-sender-id
REACT_APP_FIREBASE_APP_ID=your-app-id
REACT_APP_FIREBASE_API_KEY=AIzaSyA7aQrx-ewr86I1PiVjE4-wAaJ6GFi8hJQ
REACT_APP_FIREBASE_AUTH_DOMAIN=auth-test-23955.firebaseapp.com
REACT_APP_FIREBASE_PROJECT_ID=auth-test-23955
REACT_APP_FIREBASE_STORAGE_BUCKET=auth-test-23955.appspot.com
REACT_APP_FIREBASE_MESSAGING_SENDER_ID=1092506303099
REACT_APP_FIREBASE_APP_ID=1:1092506303099:web:31ec698e501f4f7724c0de
5 changes: 4 additions & 1 deletion my-firebase-app/src/firebase-config.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
// Import the functions from the SDKs
import { initializeApp } from "firebase/app"; // takes the configuration object and initializes your Firebase application instance
import { getAuth } from "firebase/auth"; // takes the initialized Firebase application instance and returns the authentication service for the app
import { getAnalytics } from "firebase/analytics";

const firebaseConfig = {
apiKey: process.env.REACT_APP_FIREBASE_API_KEY,
Expand All @@ -12,4 +14,5 @@ const firebaseConfig = {

const app = initializeApp(firebaseConfig);
export const auth = getAuth(app);
auth.useEmulator("http://localhost:9099");
const analytics = getAnalytics(app);
auth.useEmulator("http://localhost:9099");
Loading

0 comments on commit b2ebf26

Please sign in to comment.