diff --git a/js/js-flipper/src/client.ts b/js/js-flipper/src/client.ts index 73d2d50e7..9fc305802 100644 --- a/js/js-flipper/src/client.ts +++ b/js/js-flipper/src/client.ts @@ -214,8 +214,9 @@ export class FlipperClient { private connectToFlipper() { const url = `ws://${this.urlBase}?device_id=${this.device}${this.devicePseudoId}&device=${this.device}&app=${this.appName}&os=${this.os}`; + const encodedUrl = encodeURI(url); - this.ws = this.websocketFactory(url); + this.ws = this.websocketFactory(encodedUrl); this.ws.onerror = (error) => { this.onError(error);