[英]Configuring ember-simple-auth with ember-cli-simple-auth-token
I would like to use ember-simple-auth with ember-cli-simple-auth-token , for this, i installed and put in my configs: 我想将ember-simple-auth与ember-cli-simple-auth-token一起使用,为此,我安装并放入了配置文件:
ENV['simple-auth-token'] = {
identificationField: 'email',
serverTokenEndpoint: 'http://localhost:3000/token'
};
But i keep seen this message: 但我一直看到此消息:
No authorizer was configured for Ember Simple Auth - specify one if backend requests need to be authorized.
I installed: 我安装了:
ember install ember-cli-simple-auth
ember install ember-cli-simple-auth-token
Then generate: 然后生成:
ember g simple-auth-token ember g simple-auth-token ember g简单身份验证令牌ember g简单身份验证令牌
Am i missing some configuration? 我是否缺少某些配置?
Thanks. 谢谢。
You also need to configure: 您还需要配置:
ENV['simple-auth'] = {
authorizer: 'simple-auth-authorizer:token'
}
You should also keep in mind that you've installed a deprecated version of Simple Auth. 您还应该记住,您已经安装了过时的Simple Auth版本。 You should be using
ember-simple-auth
now. 您现在应该使用
ember-simple-auth
。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.