Comment

Comment by throwaway_bad

I was recently trying to set a cookie to "never" expire.

Apparently there's no good way to do this other than pick a date that's far enough out in the future.

A stackover answer gave an example setting it for 10 years. I thought I would be defensive and set it to 20 years.

But then it will immediately break because 32 bit dates wrap around in 2038!

Discussion

Live from the official Hacker News API

A modern reader for Hacker News · SvelteKit + Skeleton