mirror of
https://github.com/DerTyp7/teamspeak-obs-overlay.git
synced 2025-10-29 12:52:09 +01:00
add searchparams port
This commit is contained in:
@@ -1,16 +1,14 @@
|
|||||||
/* eslint-disable react-hooks/exhaustive-deps */
|
/* eslint-disable react-hooks/exhaustive-deps */
|
||||||
import "@styles/App.scss";
|
import "@styles/App.scss";
|
||||||
import { IChannel, IClient, IConnection, ITS5ConnectionHandler } from "@interfaces/teamspeak";
|
import { IClient } from "@interfaces/teamspeak";
|
||||||
import { useEffect, useState } from "react";
|
|
||||||
import Viewer from "./Viewer";
|
import Viewer from "./Viewer";
|
||||||
import { useSearchParams } from "react-router-dom";
|
import { useSearchParams } from "react-router-dom";
|
||||||
import { TS5ConnectionHandler } from "@handlers/teamspeak/connectionHandler";
|
|
||||||
import useTSRemoteApp from "./hooks/useTSRemoteApp";
|
import useTSRemoteApp from "./hooks/useTSRemoteApp";
|
||||||
|
|
||||||
export default function App() {
|
export default function App() {
|
||||||
const [searchParams] = useSearchParams();
|
const [searchParams] = useSearchParams();
|
||||||
const { clients, channels, connections, activeConnectionId, currentChannel } = useTSRemoteApp({
|
const { clients, activeConnectionId, currentChannel } = useTSRemoteApp({
|
||||||
remoteAppPort: 5899,
|
remoteAppPort: parseInt(searchParams.get("remoteAppPort") ?? "5899"),
|
||||||
});
|
});
|
||||||
|
|
||||||
return (
|
return (
|
||||||
|
|||||||
Reference in New Issue
Block a user