> For the complete documentation index, see [llms.txt](https://easonwang.gitbook.io/web_advance/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://easonwang.gitbook.io/web_advance/firebase-jiao-xue.md).

# Firebase 教學

<https://firebase.google.com/>

現在的firebase跟幾年前不同，目前提供了許多包含email link註冊，google FB oauth, Storage, Cloud function, ML kit等服務。

在小型的專案架構是很不錯的選擇，可以讓前端開發者免去開發後端的步驟。

## 認證

先 clone 此專案：<https://github.com/firebase/quickstart-js/tree/master/auth>

```
1. 註冊firebase帳號與專案
2. 下載firebase cli (可以讓你在cli上直接設定好要使用的專案)
3. 使用 firebase serve 啟動 firebase寫好的 server
4. 最後可使用 firebase deploy 部署
```

## Firestore

現在 firebase 有兩種資料庫版本，以前的 realtime db 跟新的 Firestore

Firestore使用方法可參考：

<https://firebase.google.com/docs/firestore/quickstart#web_1>
