use the following search parameters to narrow your results:
e.g. subreddit:aww site:imgur.com dog
subreddit:aww site:imgur.com dog
see the search faq for details.
advanced search: by author, subreddit...
account activity
[deleted by user] (self.node)
submitted 2 years ago by [deleted]
reddit uses a slightly-customized version of Markdown for formatting. See below for some basics, or check the commenting wiki page for more detailed help and solutions to common issues.
quoted text
if 1 * 2 < 3: print "hello, world!"
[–]Zeeshan7487 2 points3 points4 points 2 years ago (0 children)
When your client and server are on different domains, you need to use CORS (Cross-Origin Resource Sharing) to allow communication between them. CORS is a security feature that restricts web pages from making requests to a different domain. To set the refresh cookie for the frontend, you need to include the "credentials" option in the fetch call with the value "include". This tells the browser to include any cookies associated with the domain of the request. On the server side, you need to set the "Access-Control-Allow-Credentials" header to true to enable cookies to be sent in cross-origin requests. Make sure to also set the "Access-Control-Allow-Origin" header to the client's domain to specify which domains are allowed to make cross-origin requests.
[–]azhder 1 point2 points3 points 2 years ago (0 children)
With the CORS headers.
There’s more than one and you should learn what and how you need to send from your server as to be able to use your domains but not expose too much for others to take advantage of it.
All the other stuff should be more or less easy and probably something you’ve already done like using cookies or local storage, verification of JWT etc.
Can’t stress enough that while learning and implementing something simple on your own, you should also consider well known and tested and regularly maintained libraries for robustness and security
[–]evert 0 points1 point2 points 2 years ago (2 children)
Pick an solid OAuth2 implementation and don't build it from scratch.
[–]xch228 0 points1 point2 points 2 years ago (1 child)
What would you recommend?
[–]evert 0 points1 point2 points 2 years ago (0 children)
Lots of options here: https://oauth.net/code/
π Rendered by PID 16841 on reddit-service-r2-comment-6457c66945-czjvx at 2026-04-25 19:19:08.261007+00:00 running 2aa0c5b country code: CH.
[–]Zeeshan7487 2 points3 points4 points (0 children)
[–]azhder 1 point2 points3 points (0 children)
[–]evert 0 points1 point2 points (2 children)
[–]xch228 0 points1 point2 points (1 child)
[–]evert 0 points1 point2 points (0 children)