2017-04-15 32 views
0

使用最新的feathers-authentication-client和feathers-authentication-local在cookie中存储jwt token的正确方法是什么?以feathers-authentication-local身份登录的正确方式是什么,但将cookie存储在jwt中?

找不到任何文档。使用以下代码管理它在localStorage中的工作,但更喜欢将它存储在cookie中,比如羽毛 - 认证 - oauth2。

const host = 'http://localhost:3030'; 
export const app = feathers() 
    .configure(rest(host).superagent(superagent)) 
    .configure(feathers.hooks()) 
    .configure(auth({ 
    storage: localStorage, 
    type: 'jwt', 
    })); 

感谢

回答

相关问题