如何管理使用 AWS Amplify Authentication 创建的用户

How to manage users created with AWS Amplify Authentication

我正在尝试根据以下教程使用 Vue.js 构建 AWS Amplify 身份验证页面:https://dev.to/dabit3/how-to-build-production-ready-vue-authentication-23mk。我正在配置 profile.vue 组件以将与经过身份验证的用户关联的用户信息传递给模板。在本教程中,一个名为 Auth.currentAuthenticatedUser returns 的方法是一个包含有关已登录用户的元数据的 user 对象。通过在模板中将 .username 附加到 name 来访问此元数据。这是上述教程中使用 Auth.currentAuthenticatedUser 方法的组件示例:

<template>
  <h1>Welcome, {{user.username}}</h1>
</template>

<script>
import { Auth } from 'aws-amplify'

export default {
  name: 'Profile',
  data() {
    return {
      user: {}
    }
  },
  beforeCreate() {
    Auth.currentAuthenticatedUser()
      .then(user => {
        this.user = user
      })
      .catch(() => console.log('not signed in...'))
  }
}
</script>

我的问题是:创建用户后,哪个 AWS 服务实际存储该用户数据?是否有类似于Amplify或Cognito的仪表板,用于以集合的形式管理用户信息?

由于您使用的是 Amplify 和 auth class aws-amplify npm 包,我相信答案是您已经在使用 Cognito。您应该已经可以在 Cognito 中查看您的用户了。