This is HIGH-level content, 10/10 quality, 10/10 content, I'm shocked by the low viewership, I wish you all the best on your journey as a content creator
This video is just so good. EXTREMELY high quality content. Thank you very much! This is the type of video that not only adds value to other people but make them remember you and your business. Will recommend this to anyone looking to learn about WS! Wish you the utmost success!
@@AblyRealtimei got a few questions if possible. Could you make just one users object and put the connections there? Also, the on message handler needs to be inside the on connection one?
@@Cyandog You can structure the code that way if you prefer! There's no implication on functionality or performance, so it really comes down to your preference and what you find most logical to follow. Regarding the message handler - yep, that's right! - Alex
Awesome tutorial! I think I’m missing something. You’ve added useref to stop it rerendering but why does it re render so much in the first place? I thought react components only re render if state or props change?
React useWebSocket forces a render when lastJsonMessage is updated. In other words, the component renders every time a new WebSocket message is received - Alex
Since Node v.15.6.0 you don't need to install `uuid` from npm. There is a Node's native module called 'node:crypto' which exports 'randomUUID` (UUID v4) function.
Why do you have two http servers running? One is for the handshake of websocket, the other is launched from vite for react frontend. Is this the correct way to handle the websocket?
Are the hackthon projects repos available want to do sth close to uber so if there is a blog on that as well or a video that be created with react or react native that would be great
Good question. To the best of my understanding, useRef is equivalent to useCallback with an empty dependencies array. They both accomplish the same thing, which is to reference a variable between re-renders - Alex
Correct - when the user count is extremely high, broadcasting a message to every single client using a loop can lead to performance issues. In such cases, more complex solutions such as pub/sub models or a Message Queue system might be needed. These solutions allow the server to handle a much larger number of connections simultaneously. - Alex
Such a quality content there! 👍 Websocket has been overwhelming for me as a socket io user, and this expalins a very decent way love it. I really hope to see more educational contents like this from this channel and alst but not least Ably looks really interesting to give a try too!
Hello, we have another recent video called 'How to scale WebSockets to millions of connections' which you might find helpful: th-cam.com/video/vXJsJ52vwAA/w-d-xo.html - let us know if you have any questions
I’m the author of react-use-websocket, and stumbled on this video. Your kind words made my weekend!❤
Great to hear from you, and thanks for commenting ❤️
Haha, no way, amazing to see you here! Great work on react-use-websocket!
This is HIGH-level content, 10/10 quality, 10/10 content, I'm shocked by the low viewership, I wish you all the best on your journey as a content creator
This video is just so good. EXTREMELY high quality content. Thank you very much! This is the type of video that not only adds value to other people but make them remember you and your business.
Will recommend this to anyone looking to learn about WS!
Wish you the utmost success!
Thanks for the kind words! Glad to hear you like the video.
@@AblyRealtimei got a few questions if possible. Could you make just one users object and put the connections there? Also, the on message handler needs to be inside the on connection one?
@@Cyandog You can structure the code that way if you prefer! There's no implication on functionality or performance, so it really comes down to your preference and what you find most logical to follow.
Regarding the message handler - yep, that's right! - Alex
So easy to follow and explained every step! Best cursor WebSocket video out there. Thank you!!!
Thanks very much Isabella!
I want to ask if you hve a course on nodejs? You simplify things alot and I am loving it
Thanks for the interesting video, would be great to also see how to use Ably in my projects too.
Thanks for the kind words John, we're working on more videos so stay tuned 😎
amazing video this legit a gift from the youtube recomndations
Thanks Ahmed!
Thanks for the tutorial, I really appreciate the effort. One q tho, r u rly using white mode in vs code?
Alex is just a VS code white-mode kinda guy 😎
Many thanks ! Would also love to see how to implement Ably websockets in a Next.JS app :)
Thanks for letting us know, a great suggestion!
What theme are you using. Great tutorial by the way, just wandering why you avoided using SocketIO?
Hey there! It is github light theme, and no reason to avoid SocketIO. The react-use-websocket has experimental SocketIO support now as well if needed
thank u buddy for creating this awsm content , easy to understand thanks again
Thanks for commenting!
Underrated channel.
🙌
You the man!
Extremely useful, easy to understand, perfect ^)
Thanks for a great tutorial. Appreciate it.
😁
Awesome tutorial! I think I’m missing something. You’ve added useref to stop it rerendering but why does it re render so much in the first place? I thought react components only re render if state or props change?
React useWebSocket forces a render when lastJsonMessage is updated. In other words, the component renders every time a new WebSocket message is received - Alex
Since Node v.15.6.0 you don't need to install `uuid` from npm. There is a Node's native module called 'node:crypto' which exports 'randomUUID` (UUID v4) function.
Thanks, will feed this back to the team.
Why do you have two http servers running? One is for the handshake of websocket, the other is launched from vite for react frontend.
Is this the correct way to handle the websocket?
Are the hackthon projects repos available want to do sth close to uber so if there is a blog on that as well or a video that be created with react or react native that would be great
Hello, you can find the hackathon project gallery at ably.devpost.com/project-gallery but the repos may not be public.
Why do we use useRef and not useCallback at 57:00?
Good question. To the best of my understanding, useRef is equivalent to useCallback with an empty dependencies array. They both accomplish the same thing, which is to reference a variable between re-renders - Alex
You said brodcasting using loop ? but that aint feasible right ? when user count is high
Correct - when the user count is extremely high, broadcasting a message to every single client using a loop can lead to performance issues. In such cases, more complex solutions such as pub/sub models or a Message Queue system might be needed. These solutions allow the server to handle a much larger number of connections simultaneously. - Alex
10/10
Thanks! Glad to hear you liked it!
Such a quality content there! 👍
Websocket has been overwhelming for me as a socket io user, and this expalins a very decent way love it.
I really hope to see more educational contents like this from this channel and alst but not least Ably looks really interesting to give a try too!
Using light theme is like bringing a flashlight to a laser show - let's keep it dark and mysterious, shall we?
Thanks for your feedback, we will keep it in mind for future videos.
@@AblyRealtimeyes that would be nice
Light mode is crazy
🎉 how to deploy properly ? in scalable way
Hello, we have another recent video called 'How to scale WebSockets to millions of connections' which you might find helpful: th-cam.com/video/vXJsJ52vwAA/w-d-xo.html - let us know if you have any questions
could you please use dark theme! 😅
we will next time 🥰
Awesome thing but my eyes are crying with this light IDE 😂
Hi I'm Ariful Islam leeton im software developer and website developer and co founder open A. I
Fucking spam
This guy is a monster, a psychopath, he uses light theme,
🫣