Open mildronize opened 9 months ago
hono
plugin explicitlyimport { initNammatham } from "@nammatham/core";
import { AzureFunctionsAdapter } from "@nammatham/azure-functions";
import { honoPlugin } from "@nammatham/hono"
const n = initNammatham.create(new AzureFunctionsAdapter());
const func = n.func;
const app = n.app;
const helloFunction = func
.httpGet('hello')
.handler(async ({ trigger, context }) => {
return { body: `Hello, world!` };
});
const dev = process.env.NODE_ENV === 'development';
app.register(honoPlugin({ dev }));
app.start();
hono
plugin implicitlyimport { initNammatham } from "@nammatham/core";
import { AzureFunctionsAdapter } from "@nammatham/azure-functions";
const n = initNammatham.create(new AzureFunctionsAdapter());
const func = n.func;
const app = n.app;
const helloFunction = func
.httpGet('hello')
.handler(async ({ trigger, context }) => {
return { body: `Hello, world!` };
});
app.start();
Hono server will be greater option rather than express.js https://github.com/honojs/node-server