I am developing an Angular app with AWS Cognito Authentication using Amplify Angular package. I need to override methods to get callback from signin. I installed the following packages as mentioned in the docs (from my package json):
"@aws-amplify/ui-angular": "^5.0.12"
"aws-amplify": "^6.0.21"
When I try to import; import { Amplify, Auth } from 'aws-amplify';
it does not let me do it. Gives error on importing:
Module '"aws-amplify"' has no exported member 'Auth'
But in Amplfy Auth docs, there are examples of this usage. What do I miss?
these are the official docs I follow:
https://ui.docs.amplify.aws/angular/connected-components/authenticator https://ui.docs.amplify.aws/angular/connected-components/authenticator/customization
The doc references you provided appear to be for version 5. However, the latest version v6 allows you to do it shown below.
Add import statement.
Invoke
signUp
method.Also refer to this guide Migrate from Amplify JavaScript v5 to v6 (if required).