paho.mqtt.js

The Paho JavaScript Client is a browser-based library that uses WebSockets to connect to an MQTT server.