3 ms·
Should you use WS even if you don't need to push data to the client in real-time?
by Kiro 11y ago
Should you use WS even if you don't need to push data to the client in real-time?
- atemerev 11y agoFor webapps, certainly. You'd get much responsive UI, as there is much less overhead in responding to events, which improves end-user experience. Public APIs should stay REST, perhaps.
- patates 11y agoI don't see any negative aspects of exposing the same REST API through WebSockets internally. Public API (if exists) doesn't need to change, private API loses the redundant transfer of headers and cookies.