Socket.IO dev proxy #4214
Unanswered
anthonyma94
asked this question in
Q&A
Replies: 1 comment
-
Hi! Did you find anything? I can't think of a cleaner solution than what you have now. |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
On my local development, my socket io server is running on port 3000, while my nextjs client is running on port 4200. On production they'll be under one domain. I've tried using next rewrites and http-proxy-middleware to have socket io's traffic proxied to 3000, but with no success. Can anyone instruct me on what to do? Right now I'm doing
process.env.NODE_ENV === "development" ? "http://localhost:3000/" : "/"
, but I'm looking for a cleaner way to achieve that.Beta Was this translation helpful? Give feedback.
All reactions