/sse-poc

Server Sent Events POC

Primary LanguageJavaScript

Server Sent Events POC

Run npm install in both folders

server

npm start

front

npm run dev

  • Go to http://localhost:3000/ and leave as many tabs open as you want (even in your phone, tablet, etc changing localhost with the ip)
  • Go to http://localhost:3000/admin.html in another tab
  • Press the buttons and see the magic :) (all the tabs running index.html will change their color)

The admin page is like a remote, and all the tabs recieve the commands sent by it.