amazon-archives / amazon-cognito-identity-js

Amazon Cognito Identity SDK for JavaScript
Other
984 stars 454 forks source link

AWS Cognito SDK required even if AWS SDK is already imported #671

Closed rianwouters closed 6 years ago

rianwouters commented 6 years ago

"Note that the Amazon Cognito AWS SDK for JavaScript is just a slimmed down version of the AWS Javascript SDK namespaced as AWSCognito instead of AWS. It references only the Amazon Cognito Identity service."

This suggests that if the Javascript SDK is ready included, the AWSCognito SDK is no longer needed.

The proposed approach is:

it would be nice to be able to do

however this is not currently possible because amazon-cognito-identity.min.js depends on AWSCognito

I am using the following workaround:

However, I'd prefer this being a feature in amazon-cognito-identity, even if it's not compatible with newer AWS SDK versions

itrestian commented 6 years ago

You can have a look at AWS Amplify which exposes a higher order auth component for this SDK. Maybe that can suit your use case. Also note that we will continue developing this library in the AWS Amplify repo. Also we have removed the AWS SDK dependency for this library.

https://github.com/aws/aws-amplify