This commit is contained in:
MotorTruck1221 2024-03-14 01:23:25 -06:00
parent 5154da62ab
commit 7e44d6cdb2
No known key found for this signature in database
GPG key ID: 06901A625432AC21
5 changed files with 158 additions and 152 deletions

View file

@ -1,7 +1,11 @@
import { FaAngleDown } from "react-icons/fa"; import { FaAngleDown } from "react-icons/fa";
import { useState, useEffect } from "preact/hooks" import { useState, useEffect } from "preact/hooks";
import { changeTransport } from "../../util/transports.ts"; import { changeTransport } from "../../util/transports.ts";
const wispUrl = localStorage.getItem("wispUrl") || (location.protocol === "https:" ? "wss://" : "ws://") + location.host + "/wisp/"; const wispUrl =
localStorage.getItem("wispUrl") ||
(location.protocol === "https:" ? "wss://" : "ws://") +
location.host +
"/wisp/";
interface Option { interface Option {
id: string; id: string;

View file

@ -22,7 +22,9 @@ export default function Routes() {
scope: "/~/" scope: "/~/"
}) })
.then(() => { .then(() => {
console.log("Service worker registered successfully setting transport"); console.log(
"Service worker registered successfully setting transport"
);
setTransport(); setTransport();
}); });
}); });