A
A
Anton-Pluton2018-04-16 21:03:29
JavaScript
Anton-Pluton, 2018-04-16 21:03:29

How to remember the button in cookies??

There are three buttons. How to make it so that when you click on one button, it is remembered in cookies?
And when you click on another, she already rewritten to another?

Answer the question

In order to leave comments, you need to log in

1 answer(s)
V
Vitaly, 2018-04-16
@Anton-Pluton

connect
https://github.com/js-cookie/js-cookie

// задать
Cookies.set('name', 'value');
// перезаписать
Cookies.set('name', 'value2');

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question