mirror of
https://github.com/aljazceru/ditto.git
synced 2026-01-05 06:34:24 +01:00
Boilerplate Deno stuff
This commit is contained in:
7
src/app.ts
Normal file
7
src/app.ts
Normal file
@@ -0,0 +1,7 @@
|
||||
import { Hono } from '@/deps.ts';
|
||||
|
||||
const app = new Hono();
|
||||
|
||||
app.get('/', (c) => c.text('Hono!'));
|
||||
|
||||
export default app;
|
||||
1
src/deps.ts
Normal file
1
src/deps.ts
Normal file
@@ -0,0 +1 @@
|
||||
export { Hono } from 'https://deno.land/x/hono@v3.0.2/mod.ts';
|
||||
6
src/server.ts
Normal file
6
src/server.ts
Normal file
@@ -0,0 +1,6 @@
|
||||
import 'https://deno.land/std@0.177.0/dotenv/load.ts';
|
||||
import { serve } from 'https://deno.land/std@0.177.0/http/server.ts';
|
||||
|
||||
import app from './app.ts';
|
||||
|
||||
serve(app.fetch);
|
||||
Reference in New Issue
Block a user