Skip to content

Instantly share code, notes, and snippets.

@salihgueler
Created August 26, 2022 15:00
Show Gist options
  • Save salihgueler/649a8f60464f030cad6741173b41510e to your computer and use it in GitHub Desktop.
Save salihgueler/649a8f60464f030cad6741173b41510e to your computer and use it in GitHub Desktop.
Future<void> _signUpUser() async {
if (_formKey.currentState!.validate()) {
await Amplify.Auth.signUp(
username: _usernameController.text,
password: _passwordController.text,
options: CognitoSignUpOptions(
userAttributes: <CognitoUserAttributeKey, String>{
CognitoUserAttributeKey.email: _emailController.text,
},
),
);
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment