【问题标题】:Importing Accounts Common returns undefined导入账户 常见退货 undefined
【发布时间】:2016-05-27 18:41:06
【问题描述】:

运行此代码:import { AccountsCommon } from 'meteor/accounts-base' 返回 undefined。我添加了 accounts-base 包,所以我不确定我缺少什么。

【问题讨论】:

    标签: meteor accounts


    【解决方案1】:

    我做的是

    import AccountsCommon from "meteor/accounts-base";
    
    AccountsCommon.Accounts.onLogin(function() {
    });
    

    我正在使用 Meteor 1.4.1.x。

    希望对你有用。

    【讨论】:

      【解决方案2】:

      帐户应该代替 AccountsCommon

      import { Accounts } from 'meteor/accounts-base'

      【讨论】:

      • 我已经导入了 { Accounts } 并且 AccountsCommon 是未定义的。
      猜你喜欢
      • 1970-01-01
      • 2018-05-02
      • 1970-01-01
      • 2013-04-04
      • 2023-03-27
      • 1970-01-01
      • 2014-06-11
      • 2016-03-21
      • 2021-03-01
      相关资源
      最近更新 更多