You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When running the frog dev command, an error occurs related to the Bun integration with hono/bun. The error suggests that Bun is not defined, which prevents the development server from starting correctly, though this is incorrect because Bun is available in the system.
Looks like Frog is not reading Bun dependencies correctly, although the bun serve runs perfectly fine. This affects local development environment only.
Full error log:
$ frog dev
19:07:44 [vite] Error when evaluating SSR module frames-frog-api/src/index.tsx: failed to import "hono/bun"|- ReferenceError: Bun is not defined
at frames-frog-api/node_modules/hono/dist/adapter/bun/ssg.js:3:17
at ModuleJob.run (node:internal/modules/esm/module_job:222:25)
at async ModuleLoader.import (node:internal/modules/esm/loader:323:24)
at async nodeImport (frames-frog-api/node_modules/vite/dist/node/chunks/dep-CzJTQ5q7.js:53536:15)
at async ssrImport (frames-frog-api/node_modules/vite/dist/node/chunks/dep-CzJTQ5q7.js:53392:16)
at async eval (/Users/mmorek/Projects/ponder/frames-frog-api/src/index.tsx:6:31)
at async instantiateModule (frames-frog-api/node_modules/vite/dist/node/chunks/dep-CzJTQ5q7.js:53451:5)
node:internal/process/promises:289
triggerUncaughtException(err, true /* fromPromise */);
^
ReferenceError: Bun is not defined
at frames-frog-api/node_modules/hono/dist/adapter/bun/ssg.js:3:17
at ModuleJob.run (node:internal/modules/esm/module_job:222:25)
at async ModuleLoader.import (node:internal/modules/esm/loader:323:24)
at async nodeImport (frames-frog-api/node_modules/vite/dist/node/chunks/dep-CzJTQ5q7.js:53536:15)
at async ssrImport (frames-frog-api/node_modules/vite/dist/node/chunks/dep-CzJTQ5q7.js:53392:16)
at async eval (/Users/mmorek/Projects/ponder/frames-frog-api/src/index.tsx:6:31)
at async instantiateModule (frames-frog-api/node_modules/vite/dist/node/chunks/dep-CzJTQ5q7.js:53451:5)
Node.js v20.12.2
error: script "dev" exited with code 1
If that's the case, the Frog integration docs for Bun need to be updated as they currently guide people to add hono/bun instead, causing the issue to begine with. See below:
Describe the bug
When running the
frog dev
command, an error occurs related to the Bun integration withhono/bun
. The error suggests that Bun is not defined, which prevents the development server from starting correctly, though this is incorrect because Bun is available in the system.Looks like Frog is not reading Bun dependencies correctly, although the
bun serve
runs perfectly fine. This affects local development environment only.Full error log:
Link to Minimal Reproducible Example
https://github.com/matthewmorek/frames-frog-api
Steps To Reproduce
bun dev
From scratch:
serveStatic
fromfrog/serve-static
tohono/bun
bun dev
Frog Version
0.12.2
TypeScript Version
5.5.3
Check existing issues
Anything else?
No response
The text was updated successfully, but these errors were encountered: