npm install
npm run dev
- open http://localhost:2018 in your browser
The server code is located in server.ts file. It serves static front-end files from the www/dist folder, provides REST API as well as websocket connection.
Front-end is built using parcel bundler.
The server grabs each participant code-pen each 5 seconds to check if it has been changed. If so - notifies all WS clients about that. After that - FE uses /fetch endpoint to load full-page version of the changed code-pen.