Compare commits

...

2 Commits

2 changed files with 8 additions and 2 deletions

View File

@@ -67,7 +67,8 @@ export default function EventPage() {
.then(({ io }) => {
if (!mounted) return;
const socketPort = process.env.NEXT_PUBLIC_SOCKET_PORT || "4000";
const socket = io(`http://10.20.0.188:${socketPort}`, {
const socketHost = process.env.NEXT_PUBLIC_SOCKET_HOST || window.location.hostname;
const socket = io(`http://${socketHost}:${socketPort}`, {
autoConnect: true
});
socketRef.current = socket;

View File

@@ -1,7 +1,12 @@
import type { NextConfig } from "next";
const nextConfig: NextConfig = {
/* config options here */
allowedDevOrigins: ["10.20.0.188"],
experimental: {
turbo: {
// Turbopack specific configuration if needed
}
}
};
export default nextConfig;