DEV Community

Luke O'Connell
Luke O'Connell

Posted on

Today I learned-The cookies hash

One feature of HTTP requests is that the server stores a set of key-value pairs in the client, which is known as cookies. We can set access to cookies in Sinatra and Rails. We can use hash methods like .keys and .fetch with the cookies hash. Signing in a user is the most important thing that we use the cookies hash for. Only strings can be stored in the cookies hash.

Top comments (0)