From 5b9590329a1d580caedfafe7af447d7e4d6a8d7a Mon Sep 17 00:00:00 2001 From: vil02 <65706193+vil02@users.noreply.github.com> Date: Wed, 5 Feb 2025 20:23:57 +0100 Subject: [PATCH] [Docs Site] Remove trailing spaces --- src/content/docs/pub-sub/learning/websockets-browsers.mdx | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/content/docs/pub-sub/learning/websockets-browsers.mdx b/src/content/docs/pub-sub/learning/websockets-browsers.mdx index 43bd6570e7ae48..33f4ceb01ce4fc 100644 --- a/src/content/docs/pub-sub/learning/websockets-browsers.mdx +++ b/src/content/docs/pub-sub/learning/websockets-browsers.mdx @@ -35,7 +35,7 @@ In this example, we use MQTT.js’s WebSocket support to subscribe to a topic an :::note -You can view a live demo available at [demo.mqtt.dev](http://demo.mqtt.dev) that allows you to use your own Pub/Sub Broker and a valid token to subscribe to a topic and publish messages to it. +You can view a live demo available at [demo.mqtt.dev](http://demo.mqtt.dev) that allows you to use your own Pub/Sub Broker and a valid token to subscribe to a topic and publish messages to it. ::: In a real-world deployment, our publisher could be another client, a native MQTT client, or a WebSocket client running on a remote server elsewhere. @@ -54,7 +54,7 @@ function example(url) { password: jwt, // pass this from a form field in your app clientId: '', }) - + client.on('connect', function () { client.subscribe(topic, function (err) { if (err) { @@ -63,7 +63,7 @@ function example(url) { console.log(`subscribed to ${topic}`) } }) - + client.on('message', function (topic, message) { let line = (new Date()).toLocaleString('en-US') + ": " + message.toString() + "\n"; console.log(line)