Closed bard10 closed 7 years ago
I met the same problem
Actually it is working as expected :). You are just overwriting defaults with invalid values. For example, try with this:
let key = 'testCookieKey';
let value = 'testCookieValue';
let opts: CookieOptionsArgs = {
expires: new Date('2030-07-19')
};
cookieService.put(key, value, opts);
I have the same issue, without optional its working.
When i try to put cookie with CookieOptionArgs like this: ` let token: string = 'blahblahblah';
let cookieConfig: CookieOptionsArgs = { path: null, domain: null, expires: null, secure: true };
cookieService.put('accessToken', token, cookieConfig);; ` the function doesn't work (the cookie is not added) but without providing optional parameters the function works perfectly fine.