Skip to content

Commit 2c0d2df

Browse files
committed
added ref link to create users collection
1 parent 0b797e0 commit 2c0d2df

File tree

1 file changed

+17
-22
lines changed

1 file changed

+17
-22
lines changed

docs/ff-integrations/authentication/firebase-auth/google-login.md

Lines changed: 17 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -23,8 +23,7 @@ Before getting started with this section:
2323

2424
## Enable Google Sign-in Provider in Firebase
2525

26-
- Open the Firebase Console and click on Authentication
27-
- Follow the steps to enable Google Sign in for your Firebase project
26+
Open the **Firebase Console**, click on **Authentication** and then follow the steps below to enable Google Sign in for your Firebase project.
2827

2928
<iframe src="https://demo.arcade.software/I50vTFEEyhXfU82yLick?embed&show_copy_link=true" title="EcommerceFlow - Authentication - Sign-in method - Firebase console" frameborder="0" loading="lazy" webkitallowfullscreen mozallowfullscreen allowfullscreen allow="clipboard-write" width="100%" height="600"></iframe>
3029

@@ -37,21 +36,17 @@ You can create your own or use the one from page templates.
3736

3837
### Add Login Action
3938

40-
- On your Google Login button, select **Actions** from the properties panel (the
41-
right menu) and select Add Action.
42-
- Search and select the Log In (under **Backend/Database > Firebase
39+
1. On your Google Login button, select **Actions** from the properties panel (the
40+
right menu) and select **Add Action**.
41+
2. Search and select the Log In (under **Backend/Database > Firebase
4342
Authentication**) action.
44-
- Set Auth Provider to Google.
43+
3. Set **Auth Provider** to **Google**.
44+
4. Enable **Create User Document** and set the **Collection** to **users**. After successful login, this will insert the user's details, such as email, name, and photo, into the *users* collection. If you haven’t already, see how to [create *users* collection](auth-initial-setup.md#creating-the-users-collection). **Note** that, If a user already exists, it won't add details again.
4545

4646
<iframe src="https://demo.arcade.software/CBVoec46awMc3yNGLuVJ?embed&show_copy_link=true" title="EcommerceFlow - FlutterFlow" frameborder="0" loading="lazy" webkitallowfullscreen mozallowfullscreen allowfullscreen allow="clipboard-write" width="100%" height="600"></iframe>
4747

48-
- Enable the **Create User Document** and set the **Collection** to **users**.
49-
After successful login, this will insert the user's account details, such as
50-
email,
51-
name, and photo, into the 'users' collection. If a user already exists, it
52-
won't add details again.
5348

54-
:::info
49+
:::tip
5550
To let users log out of your app, you can use the [**Logout**](auth-actions.md#logout-action) action.
5651
:::
5752

@@ -69,29 +64,29 @@ To let users log out of your app, you can use the [**Logout**](auth-actions.md#l
6964

7065
2. To add in Firebase console:
7166

72-
- Open the Firebase console and click on Authentication and select the
67+
1. Open the Firebase console and click on Authentication and select the
7368
Setting tab.
7469

75-
- Select **Authorized domains** from the left side menu.
70+
2. Select **Authorized domains** from the left side menu.
7671

77-
- Click **Add domain**.
72+
3. Click **Add domain**.
7873

7974
3. To add in Google cloud console:
8075

81-
- Head over to
76+
1. Head over to
8277
your [Project Credentials](https://console.cloud.google.com/apis/credentials?project=_) page.
8378

84-
- Ensure you are on the correct project. In our case, we are using the
79+
2. Ensure you are on the correct project. In our case, we are using the
8580
[EcommerceFlow demo project](https://bit.ly/ff-docs-demo-v1), it will be different for you.
8681

87-
![credential-page.png](../imgs/credential-page.png)
82+
![credential-page.png](../imgs/credential-page.png)
8883

89-
- Under the '**OAuth 2.0 Client IDs**', select '**Web client** (auto created by
84+
3. Under the '**OAuth 2.0 Client IDs**', select '**Web client** (auto created by
9085
Google Service)'.
9186

92-
- Under the '**Authorized JavaScript origins**', click ADD URI and add both the
87+
4. Under the '**Authorized JavaScript origins**', click ADD URI and add both the
9388
URL.
94-
- Similarly, under the '**Authorized redirect URIs**', click ADD URI, add both
89+
5. Similarly, under the '**Authorized redirect URIs**', click ADD URI, add both
9590
the URL and append '/__/auth/handler' at the end.
9691

9792
<iframe src="https://www.loom.com/embed/efd5b99b858d4de8bca55452c6e1d20c" frameborder="0"
@@ -112,6 +107,6 @@ allowFullScreen style={{ width: '100%', height: '600px' }}></iframe>
112107
### Verify user created in Firebase Dashboard
113108

114109
To confirm the successful integration of Google authentication and the creation of users, navigate
115-
to your Firebase project > Authentication > Users and check the user entries.
110+
to your **Firebase project > Authentication > Users** and check the entries.
116111

117112
![verify-google-auth-users.png](../imgs/verify-google-auth-users.png)

0 commit comments

Comments
 (0)