Another local-storage solution.
🍩 🍩 🍩 => oOo
<script type="text/javascript" src="path/to/donut.js"></script>
<script type="text/javascript">
// ...Code here whatever you like
</script>
var oOo = require('donut.js');
// ...Code here whatever you like
oOo.cookie.get('key'); // { String } Cookie key name
oOo.cookie.getAll();
oOo.cookie.set('key', 'value', { // { String } Cookie key name and value
expires: 1, // { Number } Expires hours
domain: 'example.com', // { String } Domain
path: '/path/to/...', // { String } Path
secure: false, // { Boolean } Secure
httpOnly: false // { Boolean } HttpOnly
});
oOo.cookie.remove('key'); // { String } Cookie key name
oOo.cookie.removeAll();
donut.js © Phantr4x, Released under the MIT License.
Authored and maintained by Phantr4x