diff --git a/app/src/App.ts b/app/src/App.ts index 020cebba..0f535f8f 100644 --- a/app/src/App.ts +++ b/app/src/App.ts @@ -244,6 +244,10 @@ export class App< } get fetch(): Hono["fetch"] { + if (!this.isBuilt()) { + throw new Error("App is not built yet, run build() first"); + } + return this.server.fetch as any; }