From e10f1c4a465c51d069fdbab73cbb3d81b1cf7223 Mon Sep 17 00:00:00 2001 From: Mark Zheleznyakov Date: Wed, 19 Nov 2025 17:19:59 +0300 Subject: [PATCH] =?UTF-8?q?fix(frontend):=20=D0=A3=D0=B4=D0=B0=D0=BB=D0=B5?= =?UTF-8?q?=D0=BD=D1=8B=20=D1=84=D0=B0=D0=B9=D0=BB=D1=8B=20standalone-?= =?UTF-8?q?=D1=81=D0=B5=D1=80=D0=B2=D0=B5=D1=80=D0=B0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- apps/frontend/index.ts | 8 -------- apps/frontend/server.ts | 25 ------------------------- 2 files changed, 33 deletions(-) delete mode 100644 apps/frontend/index.ts delete mode 100644 apps/frontend/server.ts diff --git a/apps/frontend/index.ts b/apps/frontend/index.ts deleted file mode 100644 index 828b356..0000000 --- a/apps/frontend/index.ts +++ /dev/null @@ -1,8 +0,0 @@ -import { registerRootComponent } from "expo"; - -import App from "./App"; - -// registerRootComponent calls AppRegistry.registerComponent('main', () => App); -// It also ensures that whether you load the app in Expo Go or in a native build, -// the environment is set up appropriately -registerRootComponent(App); diff --git a/apps/frontend/server.ts b/apps/frontend/server.ts deleted file mode 100644 index 8fc446c..0000000 --- a/apps/frontend/server.ts +++ /dev/null @@ -1,25 +0,0 @@ -import { createRequestHandler } from 'expo-server/adapter/bun'; - -const CLIENT_BUILD_DIR = `${process.cwd()}/dist/client`; -const SERVER_BUILD_DIR = `${process.cwd()}/dist/server`; -const handleRequest = createRequestHandler({ build: SERVER_BUILD_DIR }); - -const port = process.env.PORT || 3000; - -Bun.serve({ - port: process.env.PORT || 3000, - async fetch(req) { - const url = new URL(req.url); - console.log('Request URL:', url.pathname); - - const staticPath = url.pathname === '/' ? '/index.html' : url.pathname; - const file = Bun.file(CLIENT_BUILD_DIR + staticPath); - - if (await file.exists()) return new Response(await file.arrayBuffer()); - - return handleRequest(req); - }, -}); - -console.log(`Bun server running at http://localhost:${port}`); -