【问题标题】:AWS Cognito ERROR Authenticator - No userPoolAWS Cognito 错误身份验证器 - 无用户池
【发布时间】:2018-05-08 23:16:29
【问题描述】:

我正在尝试在 React Native 上使用 AWS Cognito 设置用户登录。我已按照以下说明进行操作: http://docs.aws.amazon.com/aws-mobile/latest/developerguide/react-native-add-user-sign-in.html

我能够发布有关应用程序的分析并在 AWS Pinpoint 上查看包含数据的图表,但 Cognito 似乎无法正常工作

我尝试过的事情:

重新下载 aws-exports.js

awsmobile 拉动

【问题讨论】:

  • 我在 ionic 应用程序中遇到了同样的错误,有什么想法吗?

标签: react-native aws-cognito


【解决方案1】:

我想通了。您必须在调用 withAuthenticator(App) 之前配置 Amplify。我只是把它放在进口的顶部。如果教程中提到了这一点,那就太好了...

import Amplify from 'aws-amplify-react-native';
import aws_exports from './aws-exports';
import { withAuthenticator, API } from 'aws-amplify-react-native';
Amplify.configure(aws_exports); 

【讨论】:

    猜你喜欢
    • 2017-01-02
    • 2018-04-05
    • 2020-11-25
    • 2016-08-18
    • 2017-12-03
    • 2022-06-19
    • 1970-01-01
    • 2018-01-29
    • 2018-06-03
    相关资源
    最近更新 更多