thereturning
KPCKevin Powell - Community
•Created by thereturning on 9/29/2024 in #front-end
help vite proxy running in a container
I used docker compose for frontend and backend, and i tried connecting to http://backend:5500, which works, but in my vite proxy i tried setting it to that, and it didnt work. Its probably because the request is made on the browser, not in the container, so I put http://localhost:5500 as the proxy but that doesnt work.
If I directly do fetch ("localhost:5500 / ") there is no problem, so im thinking vite tries to check if the proxy is valid.
heres is my vite config
2 replies
KPCKevin Powell - Community
•Created by thereturning on 9/10/2024 in #back-end
websocket design for messagin app
can i get help me with my websocket design
i have a message app like discord, it has servers groupchats and dms, and they all have channels. messages are tied to the channels.
when a user goes in the app, i have a map that maps channel_id to a list of websocket connections. When someone sends a message, it will broadcast that message to everyone in the channel.
now i am wondering if i should have the client listen to all dms and groupchats, but for server channls listen for messages in the active channel.
to do that, i would have to remove and add the user's connection to the new active channel, which requires knowledge of the previous active channel, and which websocket connection belongs to the user.
and there is also the problem if the same user opens another tab, now i dont know which websocket connection belongs to which tab.
is my approach cooked
1 replies
KPCKevin Powell - Community
•Created by thereturning on 8/19/2024 in #front-end
help with react context
Im making a tooltip that is on the topmost part of the document, and it needs to know if a component is being hovered, that component is nested.
TooltipContext file
16 replies
KPCKevin Powell - Community
•Created by thereturning on 8/16/2024 in #front-end
my popup is being hidden
35 replies
KPCKevin Powell - Community
•Created by thereturning on 8/14/2024 in #front-end
how to style scrollbar with tailwind
this works
but webkit doesnt works
7 replies