Skip to content

Commit 10e76f1

Browse files
doc: withPhoneSignIn() callback
1 parent 82c496e commit 10e76f1

File tree

1 file changed

+16
-1
lines changed

1 file changed

+16
-1
lines changed

FirebaseSwiftUI/README.md

Lines changed: 16 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -803,7 +803,7 @@ authService
803803
public func withPhoneSignIn() -> AuthService
804804
```
805805

806-
Enables phone number authentication with SMS verification.
806+
Enables phone number authentication with SMS verification. Uses default behavior (navigates to enter phone number view when tapped).
807807

808808
**Example:**
809809

@@ -812,6 +812,21 @@ authService
812812
.withPhoneSignIn()
813813
```
814814

815+
```swift
816+
public func withPhoneSignIn(onTap: @escaping () -> Void) -> AuthService
817+
```
818+
819+
Enables phone authentication with a custom callback (i.e where to navigate when tapped) when the phone button is tapped.
820+
821+
**Example:**
822+
823+
```swift
824+
authService
825+
.withPhoneSignIn(){
826+
// navigate to phone sign-in screen logic
827+
}
828+
```
829+
815830
---
816831

817832
##### Sign in with Apple

0 commit comments

Comments
 (0)