2
我可以看到withCredentials: true
is implemented in angular 2 now角2个GET withCredentials(接受来自服务器的cookies)
要接受来自服务器的cookies。
但是我不知道我该如何使用它。
我试图
this.http.get(API_PATH + 'auth/getSession/' + TOKEN, {
withCredentials: true
})
但西兰花抛出错误
Argument of type '{ withCredentials: boolean; }' is not assignable to parameter of type 'RequestOptionsArgs'
我用角CLI的1.0.0-beta.6。
什么版本的Angular 2在'packages.json'中使用? – rinukkusu