0

https://developers.google.com/web/updates/2017/06/credential-management-updates

从那以后有什么变化吗?

  if (window.PasswordCredential) {
    let credential = new window.PasswordCredential({
      id: "ABC",
      password: "DEF",
      name: "NAME"
    });
    navigator.credentials.store(credential);
  }

成功存储凭据。

let cred = navigator.credentials.get({password: true, mediation: "silent"}).then(
  c => {
    console.log(c)
  })

未定义的日志。

删除中介或将其设置为可选或必需会弹出帐户选择器,然后返回预期的凭据。

我在这里想念什么?

4

0 回答 0