Skip to content

Commit 25f967d

Browse files
resolve comments
1 parent a3f6964 commit 25f967d

3 files changed

Lines changed: 21 additions & 9 deletions

File tree

docs/sdk/core-kit/sfa-flutter/install.mdx

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -5,10 +5,10 @@ displayed_sidebar: sdk
55
description: "Web3Auth Core Kit Single Factor Auth Flutter SDK - Install | Documentation - Web3Auth"
66
---
77

8-
## `single_factor_auth_flutter`
8+
## [single_factor_auth_flutter](https://pub.dev/packages/single_factor_auth_flutter)
99

10-
To install the `single_factor_auth_flutter` package, you have two options. You can either manually add the package in the `pubspec.yaml` file, or you
11-
can use the `flutter pub add` command.
10+
To install the `single_factor_auth_flutter` package, you have two options. You can either manually
11+
add the package in the `pubspec.yaml` file, or you can use the `flutter pub add` command.
1212

1313
Add `single_factor_auth_flutter` as a dependency to your `pubspec.yaml`.
1414

@@ -17,7 +17,7 @@ dependencies:
1717
single_factor_auth_flutter: ^2.0.1
1818
```
1919
20-
Add `single_factor_auth_flutter` using `flutter pub add command`.
20+
Add `single_factor_auth_flutter` using `flutter pub add` command.
2121

2222
```sh
2323
flutter pub add single_factor_auth_flutter

docs/sdk/core-kit/sfa-ios/install.mdx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ description: "Installing Web3Auth SFA iOS SDK | Documentation - Web3Auth"
1111

1212
1. In Xcode, with your app project open, navigate to **File > Add Packages**.
1313

14-
1. When prompted, add the tKey iOS SDK repository:
14+
1. When prompted, add the single-factor-auth-swift iOS SDK repository:
1515

1616
```sh
1717
https://github.com/Web3Auth/single-factor-auth-swift

src/pages/guides/sfa-flutter-firebase.mdx

Lines changed: 16 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -192,10 +192,22 @@ final userCredential = await firebaseHelper.signInWithEmailAndPassword(
192192
'Testing@123',
193193
);
194194
195-
final torusSFAKey = await singleFactorAuthFlutter.getKey(userCredential.user);
195+
final user = userCredential.user;
196+
final token = await user.getIdToken(true);
196197
197-
log(torusSFAKey.privateKey);
198-
log(torusSFAKey.publicAddress);
198+
final loginParams = LoginParams(
199+
// Replace with your verifier
200+
verifier: 'web3auth-firebase-examples',
201+
// Replace with the verifierId value, can be email, sub, or custom
202+
verifierId: 'sfa.flutter@w3a.link',
203+
idToken: token!,
204+
)
205+
206+
// highlight-next-line
207+
final torusKey = await singleFactAuthFlutter.getKey(loginParams);
208+
209+
log(torusKey.privateKey);
210+
log(torusKey.publicAddress);
199211
```
200212

201213
## Set up Blockchain Providers
@@ -260,4 +272,4 @@ Voila, you have learned how to use Web3Auth SFA SDK with Flutter application.
260272
If you are interested in learning more about SFA SDK, please checkout our
261273
[documentation for Flutter SFA SDK](/docs/sdk/core-kit/sfa-flutter/). You can find the code used for
262274
the guide on our
263-
[examples repo](https://github.com/Web3Auth/web3auth-core-kit-examples/tree/main/single-factor-auth-flutter/sfa-flutter-quick-start).
275+
[examples repo](https://github.com/Web3Auth/web3auth-core-kit-examples/tree/main/single-factor-auth-flutter/sfa_flutter_quick_start).

0 commit comments

Comments
 (0)