@huddle01/web-core
Advanced tools
Comparing version 1.0.0-alpha.0 to 1.0.0-alpha.1
@@ -62,2 +62,7 @@ import { EnhancedEventEmitter } from "common-js/EnhancedEventEmitter"; | ||
this.projectId = data.projectId; | ||
const isLocalDev = this.projectId === "development"; | ||
if (isLocalDev) { | ||
logger.info("🔴 Local Development Mode"); | ||
this.socket.enableLocalDev(); | ||
} | ||
this.localPeer = LocalPeer.create(); | ||
@@ -64,0 +69,0 @@ this.room.once("room-left", () => { |
@@ -50,2 +50,3 @@ import { ClientToSushiEvents } from "types/dist/clientToSushiEvents.types"; | ||
private __ENDPOINT; | ||
private isLocalDev; | ||
/** | ||
@@ -110,2 +111,3 @@ * Token of the current socket connection, specific to the Local Peer who joined the meeting | ||
private __getRegion; | ||
enableLocalDev: () => void; | ||
/** | ||
@@ -112,0 +114,0 @@ * Connect to the socket server using the token |
@@ -35,2 +35,3 @@ import { mainLogger } from "./logger"; | ||
__ENDPOINT = null; | ||
isLocalDev = false; | ||
/** | ||
@@ -146,2 +147,5 @@ * Token of the current socket connection, specific to the Local Peer who joined the meeting | ||
}; | ||
enableLocalDev = () => { | ||
this.isLocalDev = true; | ||
}; | ||
/** | ||
@@ -274,3 +278,5 @@ * Connect to the socket server using the token | ||
} | ||
const apiServerUrl = "http://localhost:8000/api/v1"; | ||
const apiServerUrl = this.isLocalDev | ||
? "http://localhost:8000/api/v1" | ||
: "https://apira.huddle01.com/api/v1"; | ||
const res = await fetch(`${apiServerUrl}/getSushiUrl`, { | ||
@@ -277,0 +283,0 @@ method: "GET", |
{ | ||
"name": "@huddle01/web-core", | ||
"version": "1.0.0-alpha.0", | ||
"version": "1.0.0-alpha.1", | ||
"description": "", | ||
@@ -5,0 +5,0 @@ "type": "module", |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
Major refactor
Supply chain riskPackage has recently undergone a major refactor. It may be unstable or indicate significant internal changes. Use caution when updating to versions that include significant changes.
Found 1 instance in 1 package
280018
6739
2