Create a JavaScript class called Cookie. The class should have:
- a private property, name, the name of the cookie
- a constructor with one parameter that sets the name property
- a method that gets the cookie’s value
- a method that sets sets the cookie’s value
The class should use JavaScript cookies so that when the web browser is closed and reopend the value of the cookie is preserved. Note, it should work even when there are multiple cookies stored for the web site. It can use any experation date that will allow the cookies to persist between opening and closing the browser.
Submission
Submit your code on the course Inquire site.