Conversation
Notices
-
Embed this notice
Fish of Rage (sun@shitposter.world)'s status on Tuesday, 14-Jan-2025 14:25:01 JST Fish of Rage
I spent hours trying to get something working in ReactJS, did some Internet searching and found out everybody has this problem. Problem being, using a websocket to feed a component data. When you're running in dev mode, React intentionally renders every component twice just to punish you. - Haelwenn /элвэн/ :triskell: and iced depresso like this.
-
Embed this notice
Fish of Rage (sun@shitposter.world)'s status on Tuesday, 14-Jan-2025 14:25:25 JST Fish of Rage
The solution ended up being "disable strict mode" which is the thing that double-renders. -
Embed this notice
Fish of Rage (sun@shitposter.world)'s status on Tuesday, 14-Jan-2025 14:26:50 JST Fish of Rage
Not only is React a pile of spaghetti, it forces you to write spaghetti, there is no sane alternative. -
Embed this notice
iced depresso (icedquinn@blob.cat)'s status on Tuesday, 14-Jan-2025 14:29:05 JST iced depresso
@sun is that some kind of internal sanity check -
Embed this notice
dirb (dirb@pleroma.dirb.xyz)'s status on Tuesday, 14-Jan-2025 14:30:31 JST dirb
@sun I had a similar problem with web sockets and angular. When you run it on de mode angular would connect both from the node instance running ng and the browser, apparently some of logic gets duplicated Fish of Rage likes this. -
Embed this notice
Hyperhidrosis (hyperhidrosis@shitposter.world)'s status on Tuesday, 14-Jan-2025 14:31:05 JST Hyperhidrosis
@sun try svelte -
Embed this notice
Fish of Rage (sun@shitposter.world)'s status on Tuesday, 14-Jan-2025 14:31:05 JST Fish of Rage
@Hyperhidrosis I had to start with react on this -
Embed this notice
Fish of Rage (sun@shitposter.world)'s status on Tuesday, 14-Jan-2025 14:31:13 JST Fish of Rage
@icedquinn its so easy to do things wrong that they do this on purpose to make you do it right by breaking your shit early. the problem is that it isn't good for everything. -
Embed this notice
iced depresso (icedquinn@blob.cat)'s status on Tuesday, 14-Jan-2025 14:32:12 JST iced depresso
@sun :blobcatgoogly: i only really looked in to preact, and only a little, and it seems svelte/solid are even better, so idk -
Embed this notice
Fish of Rage (sun@shitposter.world)'s status on Tuesday, 14-Jan-2025 14:33:08 JST Fish of Rage
@icedquinn svelte and vue are better than react.