cescoffier / quarkus-langchain4j-workshop

Learn how to build AI-infused applications with Quarkus
https://cescoffier.github.io/quarkus-langchain4j-workshop/
Apache License 2.0
6 stars 5 forks source link

Improve WebSocket scheme computation #18

Open cescoffier opened 3 weeks ago

cescoffier commented 3 weeks ago

At the moment it does not check if it needs to connect using ws:// or wss://

We need:

var protocol = (window.location.protocol == “https:“) ? “wss” : “ws”;
const socket = new WebSocket(protocol + “://” + window.location.host + “/chatbot”);

This need to be added to all the HTML pages.