Know that CORS configurations can be a bit of pain...
# sst
s
Know that CORS configurations can be a bit of pain. I wanted to prove out a solution of HTTP Only Secure cookies that my frontend would utilise against the backend. Have created an example repository to showcase this configuration; https://github.com/ctrlplusb/sst-cors-example
It ain't ultra-strict. You'll likely want to reduce some of the
*
values in the CORS config, and ideally switch the cookie to SameSite.
Locally I prefer to set up an /etc/hosts domain for my frontend, and then utilise mkcert to generate an SSL certificate to allow it run over HTTPS. That's a bit more complicated and I didn't want to overburden the example.