feat(new): scaffold core 26.9.0-beta.2, and boot before binding on Deno and Bun

beta.2 made serveDeno and serveBun boot the app before they bind. The
starters called Deno.serve and Bun.serve with app.fetch directly, so a
provider that failed left an open port answering 500 to everything.

Signed-off-by: Diego Resendez <diego.resendez@zero-oneit.com>
This commit is contained in:
chrnx committed 2026-09-24 12:58:16 -05:00
1 parent 42c1148903
commit efe7ad6027
3 files changed
+18 -5

No files matched your search

+5 -1
View File
@@ -1,4 +1,8 @@
import { serveBun } from '@green-tea/core/bun';
import { app } from './app';
Bun.serve({ port: 8000, fetch: app.fetch });
// Boots before it binds: a provider that fails stops the process here, instead
// of leaving an open port that answers 500 to everything.
await serveBun(app, { port: 8000 });
console.log('🍵 green-tea running on http://localhost:8000');
+5 -1
View File
@@ -1,4 +1,8 @@
import { serveDeno } from '@green-tea/core/deno';
import { app } from './app';
Deno.serve({ port: 8000 }, app.fetch);
// Boots before it binds: a provider that fails stops the process here, instead
// of leaving an open port that answers 500 to everything.
await serveDeno(app, { port: 8000 });
console.log('🍵 green-tea running on http://localhost:8000');