Sometimes you just need to look at the same code with someone: a quick pairing session, an interview question, a snippet a colleague can't get working. Screen sharing is laggy and nobody else can type. Full collaborative IDEs are heavy for a five-minute job.
So I built Code Share , a share-a-link code editor, as part of ToolkitHub. This post is about the architecture, including the shortcuts I took on purpose and where they stop working.
Rooms are just URLs
There is no sign-up. Opening https://code.toolkithub.in/anything puts you in a room called anything ; opening the bare domain generates a random room ID and pushes it into the address bar. Sharing the room means sharing the URL. You pick a display name, and everyone in the room sees each other's presence and cursors.
The sync model: whole document, last write wins
The editor is Ace in React, connected to a Node server over Socket.IO. When you type, the client sends the full document:
// server socket .…