Can't set cookies on the client-side

I was able to solve the issue. It turned out that what I needed was to include the SameSite option in my cookie settings. Once I added this option, I was able to successfully set cookies.

Here’s the code I used to set the cookie:

document.cookie = myCookie=myValue; SameSite=None; Secure; Max-Age=31536000;