Closed sethdorris closed 8 years ago
which means the library as is... you can't set a secure cookie.
It looks right here .. but installing from npm may be the cause?
/**
* Class Cookie - Holds static functions to deal with Cookies
*/
export declare class Cookie {
/**
* Retrieves a single cookie by it's name
*
* @param {string} name Identification of the Cookie
* @returns The Cookie's value
*/
static get(name: string): string;
/**
* Retrieves a a list of all cookie avaiable
*
* @returns Object with all Cookies
*/
static getAll(): any;
/**
* Save the Cookie
*
* @param {string} name Cookie's identification
* @param {string} value Cookie's value
* @param {number} expires Cookie's expiration date in days from now. If it's undefined the cookie is a session Cookie
* @param {string} path Path relative to the domain where the cookie should be avaiable. Default /
* @param {string} domain Domain where the cookie should be avaiable. Default current domain
*/
static set(name: string, value: string, expires?: number, path?: string, domain?: string): void;
/**
* Removes specified Cookie
*
* @param {string} name Cookie's identification
* @param {string} path Path relative to the domain where the cookie should be avaiable. Default /
* @param {string} domain Domain where the cookie should be avaiable. Default current domain
*/
static delete(name: string, path?: string, domain?: string): void;
/**
* Delete all cookie avaiable
*/
static deleteAll(path?: string, domain?: string): any;
}
this is ng2-cookies/services/cookies.d.ts after running NPM install, you can see where I am talking about at static set
hey seth I did the npm install over here, and it comes with the secure param, I have no idea why it is happening with you.. cookie.d.ts and cookie.js has the param
I'll see if I can replicate the issue in another repo. Thanks for checking it out @HerbertNatal
I didn't have this option when I imported with ng2-cookies/ng2-cookies
, but when I changed the import to just ng2-cookies
I had the secure
options available to me.
the typings for set does not have the parameter of acceptance for Secure.