Step 1 / 12Setup
HTTP: the client always speaks first
A normal HTTP request is a question and an answer. The browser asks, the server answers, and the conversation ends. The server cannot start talking on its own.
But many features need the server to speak first: a new chat message, a price change, a notification, the next token from an AI model. How do we do it?
“With plain HTTP the client always asks first, so we need a technique to let the server push updates.”
←→ step·R restart·Space pause