- Fixed null object reference error when both the global this and window objects are undefined (e.g., when using webpack).
- Fixed errors caused when accessing a properly encoded cookie while another cookie had a malformed key/value.
- Fixed bower.json and package.json
mainpointing to "src" instead of "dist" now that an unminified version lives in "dist"
Infinitymay now be used with the "expires" option to set a persistent cookie.- Included unminified version of the library in "dist"
- Added the ability to require Cookies.js in CommonJS/Node environments that do not natively have a
windowobject, by exporting a factory method that takes an instance of awindow.
- Fixed being unable to retrieve cookie values for keys that were named the same as a built-in
Objectproperty.
- Put Cookies.js into the public domain.
- Explicitly defaulted the
secureoption tofalse.
- Replaced deprecated
toGMTStringwithtoUTCString(Thanks @Zorbash!) - Added a proper bower.json file (Thanks @jstayton!)
- Fixed bug where
Cookies.enabledwas always returning true in IE7 and IE8 (Thanks @brianlow!) - Updated cookies.d.ts for Typescript 1.0 (Thanks @flashandy!)
- Fixed unnecessarily encoding characters in cookie keys that are allowed by RFC6265, and fixed not encoding a couple characters in cookies keys that are not allowed by RFC6265. (Issue #18)
- Moved the change log to its own file.
- Fixed a runtime error that prevented the library from loading when cookies were disabled in the client browser.
- Fixed a bug in IE that would cause the library to improperly read cookies with a value of
"".
- Rewrote the library from the ground up, using test driven development. The public API remains unchanged.
- Restructured project directories.
- Properly escaped a
[literal in the RFC6265 regular expression.
- Cookie values are no longer automatically JSON encoded/decoded. This featured was deemed out of the scope of the library. This change also removes the dependency on a JSON shim for older browsers.
- Changed cookie value encoding to only encode the special characters defined in RFC6265
- Added
'use strict';directive. - Removed some extraneous code.
- Added CommonJS module support.
- Setting an
undefinedvalue withCookies.setnow expires the cookie, mirroring theCookies.expirealias syntax. - Simplified how the
document.cookiestring is parsed.
- Fixed a bug where setting a cookie's
securevalue tofalsecaused theCookies.defaults.securevalue to be used instead.
- Added aliases for
Cookies.setandCookies.expire.
- Set
Cookies.defaults.pathto'/'. - Replaced
escapeandunescapefunction calls withencodeURIComponentanddecodeURIComponent, because the former are deprecated. - Cookie keys are now URI encoded in addition to cookie values.
- Cross browser fixes.
- Initial commit.