import * as build from '@remix-run/dev/server-build'
it doesn't work with the following error:
handler could not be imported: Error: @remix-run/dev/server-build is not meant to be used directly from node_modules. It exists to provide type definitions for a virtual module provided by the Remix compiler at build time.
So I change the import to the build output from vite:
import * as build from "../build/server/remix";
I've got a new error:
handler could not be imported: Error: Dynamic require of "http" is not supported
From what I see my issue comes from the entry.server.tsx file which use createReadableStreamFromReadable which requires native node module "http" that is not available. I think I've to recreate this file to work with Hono. any idea how can I do it ? Do you have an exemple I can used?
Am I doing something wrong ?
I'm building the function that I deploy using esbuild that's how I managed to track what was requiring the http module.
If I import the build like :
it doesn't work with the following error:
So I change the import to the build output from vite:
I've got a new error:
From what I see my issue comes from the
entry.server.tsx
file which usecreateReadableStreamFromReadable
which requires native node module "http" that is not available. I think I've to recreate this file to work with Hono. any idea how can I do it ? Do you have an exemple I can used? Am I doing something wrong ? I'm building the function that I deploy using esbuild that's how I managed to track what was requiring the http module.