Home » Computer Science » HTML5 » What is the main purpose of the HTML5 WebSocket API?

What is the main purpose of the HTML5 WebSocket API?

A. To handle offline storage
B. To establish a persistent connection for real-time data exchange
C. To create animations
D. To enhance page load speeds

Option: B