Spaces:
Sleeping
Sleeping
Download src/shared/services/bootstrap.js from automindy/sdkongwang: direct link, hf CLI and curl.
- Browser
- Download file 613 Bytes
-
https://huggingface.co/spaces/automindy/sdkongwang/resolve/main/src/shared/services/bootstrap.js
- Command line
-
hf download hf://spaces/automindy/sdkongwang/src/shared/services/bootstrap.js
-
curl -L -o bootstrap.js https://huggingface.co/spaces/automindy/sdkongwang/resolve/main/src/shared/services/bootstrap.js
613 Bytes
| import initializeApp from "./initializeApp.js"; | |
| // Skip during Next.js build/prerender — bootstrap would download cloudflared, init DNS, etc. | |
| const isBuildPhase = process.env.NEXT_PHASE === "phase-production-build" | |
| || process.env.NEXT_PHASE === "phase-export" | |
| || process.env.NEXT_PHASE === "phase-static"; | |
| // Server-only singleton: guard via global so HMR / re-imports don't double-init | |
| if (typeof window === "undefined" && !isBuildPhase && !global.__appBootstrapped) { | |
| global.__appBootstrapped = true; | |
| initializeApp().catch((e) => console.error("[Bootstrap] init failed:", e.message)); | |
| } | |