amazon-archives / amazon-cognito-auth-js

The Amazon Cognito Auth SDK for JavaScript simplifies adding sign-up, sign-in with user profile functionality to web apps.
Apache License 2.0
423 stars 232 forks source link

React Integration or Sample App #23

Open mgalindo opened 7 years ago

mgalindo commented 7 years ago

Are there any plans to provide a React Sample application?

rcfrias commented 7 years ago

I wish there was. This project doesn't move very often, but there is a chance someone at the team, catches your request when they do.

glicht commented 7 years ago

In case it helps I have a fork of the sample app configured to an actual user pool. It helped me understand the flow and get started. You can browse at:

https://rawgit.com/guylichtman/amazon-cognito-auth-js/master/sample/index.html

jaxondu commented 6 years ago

Found this repo by AWS staff using VueJS, it however does not use any AWS SDK, just a standard call using Axios to Cognito API endoints. Tested it and its working. However the endpoint it uses is different. For example the AWS doc says endpoint is "/oauth2/authorize", but the repo below uses "/authorize".

https://github.com/PaulMaddox/aws-vuejs-cognito

yuntuowang commented 6 years ago

@mgalindo We don't have a React integration now but I will mark this as a feature request. However, we cannot estimate the delivery time at this point. Also, @jaxondu both "/oauth2/authorize" and "/authorize" will work, but we recommend using "/oauth2/authorize".

gabeweaver commented 6 years ago

@mgalindo Here is how i've implemented Cognito User Pools and Cognito Identity with this SDK and the Cognito ID SDK in a vanilla create-react-app:

https://gist.github.com/gabeweaver/d1be9f0d41069437f576c375c30e134c

ahmetcetin commented 6 years ago

late to the party but check this out: https://github.com/patmood/react-aws-cognito-example/blob/master/README.md