LazWebsockets
LazWebsockets copied to clipboard
Allow handling pure HTTP
Hello,
thank you for sharing this component.
My request is to allow registering a handler for pure HTTP requests, or some kind of "bypass" for the Websockets. Currently, your Websocket implementation doesn't support HTTP whereas FPC's HTTP server doesn't support Websocket. Normally this wouldn't be an issue, but because HTTP and Websocket share the same port, there should be a way to have the Websocket server to respond only on certain paths while allowing HTTP on other paths.
Imho, it'd be sufficient if one could just have an own handler invoked before the Websocket handshake is performed.