12
b2plane
1y

I am so much stunned i cannot form a sentence on what to say. Lost 3 days trying to fix a bug on why socket.io was connecting to backend TWICE per user. I cannot fucking comprehend this. Backend works fine because via postman it doesnt connect twice. Everything works fine. 72 fucking hours waste d of my life just to find out i had to change

<React.StrictMode>
<App />
</React.StrictMode>

Into

<App />

When i tell you my jaw fucking dropped it fucking did. And it does not drop often or that easily for me. What the FUCK is react strict mode???? FUCK react. I fucking hate this piece of garbage framework. I even like nextjs better. React💩💩💩💩💩💩💩💩💩💩motberfucker WHY is strict mode fucking my code what use does it have who gives a shit why does it have anything to do with websocket connection FUCK react 💩💩💩💩💩💩💩💩💩 how does this piece of camel turd have anything to do with duplicate connection 💩💩💩💩MFKKCER this garbage doesnt exist in my beautiful angular or nextjs PLS why this cancer has to be so headaching i knew I'll get FUCKED if i dont go over a detailed course learning react from scratch. Now im suffering. Learning this garbage the hard way FUCK off

Comments
  • 1
    React is pure technicsl DEBT, remove as soon as possible. Never accumelate that Kind of easily paid Debt.
  • 6
  • 2
    You have one of these two bugs in your code:
  • 1
    Luckily neither are hard to find unless you did something terrible. Locate calls to socket.io that open a connection, then deep search all callers for React components or useEffect callbacks and refactor until

    1. There are no components in the caller set at all
    2. All useEffect callbacks can be statically proven to clean up the connection
Add Comment