1.0.1 • Published 3 years ago

@blanik/js-cookies v1.0.1

Weekly downloads
-
License
MIT
Repository
github
Last release
3 years ago

meCookies

By Amadeusz Blanik

The only one pure JavaScript Cookies which use same time format as Jira!

How to use


Download one of following package:

Then…

<script src="mecookies.js"></script> 
<script> 
let meCookie = new MeCookies()
meCookie.set("hello", "world", "7d")
</script>

Devmode

let meCookie = new MeCookies(true)

Options


Set

meCookie.set(
    name, 
    value, 
    time, ~ eg. "1y 2m 7d 8h"
    path ~ default path = "/"
   )
Time
y - years
m - months
d - days
h - hours

Get

meCookie.get(name)