This commit is contained in:
David Nguyen
2025-02-04 22:25:11 +11:00
parent 381a9d3fb8
commit 540cc5bfc1
35 changed files with 529 additions and 890 deletions

18
apps/remix/server/main.ts Normal file
View File

@ -0,0 +1,18 @@
// main.ts
import { serve } from '@hono/node-server';
import { serveStatic } from '@hono/node-server/serve-static';
import handle from 'hono-react-router-adapter/node';
import server from '.';
import * as build from '../build/server';
import { getLoadContext } from './load-context';
server.use(
serveStatic({
root: './build/client',
}),
);
const handler = handle(build, server, { getLoadContext });
serve({ fetch: handler.fetch, port: 3000 });