Spaces:
Paused
Paused
ML Intern deploy
Deploy httpSMS gateway to Hugging Face Spaces (Docker SDK): nginx :7860 -> Go API :8000, Nuxt SPA, Android APK, bootstrap-mode entrypoint
83a59ca Download web/app/middleware/guest.ts from red-kit/httpsms-gateway: direct link, hf CLI and curl.
- Browser
- Download file 478 Bytes
-
https://huggingface.co/spaces/red-kit/httpsms-gateway/resolve/main/web/app/middleware/guest.ts
- Command line
-
hf download hf://spaces/red-kit/httpsms-gateway/web/app/middleware/guest.ts
-
curl -L -o guest.ts https://huggingface.co/spaces/red-kit/httpsms-gateway/resolve/main/web/app/middleware/guest.ts
478 Bytes
| export default defineNuxtRouteMiddleware(async () => { | |
| const authStore = useAuthStore() | |
| if (!authStore.authStateChanged) { | |
| await new Promise<void>((resolve) => { | |
| const stop = watch( | |
| () => authStore.authStateChanged, | |
| (changed) => { | |
| if (changed) { | |
| stop() | |
| resolve() | |
| } | |
| }, | |
| { immediate: true }, | |
| ) | |
| }) | |
| } | |
| if (authStore.authUser !== null) { | |
| return navigateTo('/threads') | |
| } | |
| }) | |