teratail header banner
teratail header banner
質問するログイン新規登録

質問編集履歴

1

文章追加

2022/03/12 03:01

投稿

edu
edu

スコア35

title CHANGED
File without changes
body CHANGED
@@ -10,8 +10,28 @@
10
10
 
11
11
  何方かアドバイスをお願いします。
12
12
 
13
+ ```firebase.js
14
+ import { initializeApp } from "firebase/app";
15
+ import { getAuth } from "firebase/auth";
16
+ import { getFirestore } from "firebase/firestore";
13
17
 
18
+ const firebaseConfig = {
19
+ apiKey: "",
20
+ authDomain: "",
21
+ projectId: "",
22
+ storageBucket: "",
23
+ messagingSenderId: "",
24
+ appId: "",
25
+ measurementId: "",
26
+ };
27
+
28
+ export const firebaseApp = initializeApp(firebaseConfig);
29
+ export const auth = getAuth(firebaseApp);
30
+ export const firestore = getFirestore(firebaseApp);
14
31
  ```
32
+
33
+
34
+ ```
15
35
  import React, { useContext, useState } from "react";
16
36
  import { connect } from "react-redux";
17
37
  import { addTodos } from "../redux/reducer";