Skip to content

Commit

Permalink
docs: fix up some links (#7)
Browse files Browse the repository at this point in the history
  • Loading branch information
vonovak authored Apr 13, 2024
1 parent 568226d commit 87a1be9
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
6 changes: 3 additions & 3 deletions docs/one-tap.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ signature: (`params`: [`OneTapSignInParams`](api#onetapsigninparams)) => `Promis

Attempts to sign in user automatically as explained [here](<https://developers.google.com/android/reference/com/google/android/gms/auth/api/identity/BeginSignInRequest.Builder#setAutoSelectEnabled(boolean)>). On the web, this call rejects - please [read below](#web-support) for web support.

Returns a `Promise` that resolves with an object containing the user data or rejects in case of error. If there is no user that previously signed in, the promise will reject with [`NO_SAVED_CREDENTIAL_FOUND`](http://localhost:3000/docs/errors#one-tap-specific-errors) error. In that case, you can call [`createAccount`](one-tap#createaccount) to start a flow to create a new account. You don't need to call `signIn` as a response to a user action - you can call it when your app starts or when suitable.
Returns a `Promise` that resolves with an object containing the user data or rejects in case of error. If there is no user that previously signed in, the promise will reject with [`NO_SAVED_CREDENTIAL_FOUND`](errors#status-codes-specific-to-one-tap-sign-in) error. In that case, you can call [`createAccount`](one-tap#createaccount) to start a flow to create a new account. You don't need to call `signIn` as a response to a user action - you can call it when your app starts or when suitable.

<details>
<summary>UI screenshot</summary>
Expand Down Expand Up @@ -89,7 +89,7 @@ signIn = async () => {

signature: (`params`: [`OneTapSignInParams`](api#onetapsigninparams)) => `Promise`\<[`OneTapUser`](api#onetapuser)\>

Starts a flow to create a user account. It offers a list of user accounts to choose from (When multiple Google accounts are logged in on the device). Also, it can be used if `signIn` rejects with `NO_SAVED_CREDENTIAL_FOUND` error, as shown in the code snippet above. You don't need to call `createAccount` as a response to a user action - you can call it when your app starts or when suitable.
Starts a flow to create a user account. It offers a list of user accounts to choose from (When multiple Google accounts are logged in on the device). Also, it can be used if `signIn` rejects with [`NO_SAVED_CREDENTIAL_FOUND`](errors#status-codes-specific-to-one-tap-sign-in) error, as shown in the code snippet above. You don't need to call `createAccount` as a response to a user action - you can call it when your app starts or when suitable.

Returns a `Promise` that resolves with an object containing the user data or rejects in case of error. On the web, this call rejects - please [read below](#web-support) for web support.

Expand All @@ -109,7 +109,7 @@ await GoogleOneTapSignIn.createAccount({

signature: (`params`: [`OneTapSignInParams`](api#onetapsigninparams)) => `Promise`\<[`OneTapUser`](api#onetapuser)\>

Presents the sign in dialog explicitly. This is useful when the user has hit rate limiting (`ONE_TAP_START_FAILED`) and the one-tap flow is thus not available, or if both `signIn` and `createAccount` reject with `NO_SAVED_CREDENTIAL_FOUND` error - which happens (in the unlikely case) when no Google account is present on the device. This will prompt the user to add a Google account.
Presents the sign in dialog explicitly. This is useful when the user has hit rate limiting ([`ONE_TAP_START_FAILED`](errors#status-codes-specific-to-one-tap-sign-in)) and the one-tap flow is thus not available, or if both `signIn` and `createAccount` reject with `NO_SAVED_CREDENTIAL_FOUND` error - which happens (in the unlikely case) when no Google account is present on the device. This will prompt the user to add a Google account.

Call this method only as a reaction to when user taps a "sign in with Google" button.

Expand Down
2 changes: 1 addition & 1 deletion docs/original.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ sidebar_position: 40

# Original Google sign in

This module exposes the [Google Sign-In for Android (legacy)](https://developers.google.com/identity/sign-in/android/start-integrating) and [Google Sign-In for iOS](https://developers.google.com/identity/sign-in/ios/start) SDKs.
This module exposes the [Google Sign-In for Android (legacy)](https://web.archive.org/web/20240308064911/https://developers.google.com/identity/sign-in/android/start-integrating) and [Google Sign-In for iOS](https://developers.google.com/identity/sign-in/ios/start) SDKs.

:::info
Please note this documentation is for the latest version of the module which is [only available to sponsors ❤️](install). If you're not a sponsor, read the [docs here](https://github.com/react-native-google-signin/google-signin).
Expand Down

0 comments on commit 87a1be9

Please sign in to comment.