lc-elysia-logger
v0.1.3
Published
Efficient Logging Middleware Designed for Elysia Web Framework
Downloads
5
Maintainers
Readme
lc-elysia-logger
Installation
bun add lc-elysia-logger
Usage
import { lcLogger } from 'lc-elysia-logger';
import { Elysia } from 'elysia';
const app = new Elysia()
.use(lcLogger())
.group('lc-elysia-logger', (api) =>
api
.get('/', () => ({ message: 'API' }))
.post('/', () => ({ message: 'API' }))
.put('/', () => ({ message: 'API' }))
.delete('/', () => ({ message: 'API' }))
.patch('/', () => ({ message: 'API' }))
.options('/', () => ({ message: 'API' }))
.head('/', () => ({ message: 'API' }))
)
.listen(3000);
console.log(` - API is running at ${app.server?.hostname}:${app.server?.port}`);