Skip to content

Commit

Permalink
docs(readme): add customLogMessage to options table
Browse files Browse the repository at this point in the history
  • Loading branch information
PunGrumpy committed Apr 8, 2024
1 parent f1ca740 commit 6898832
Showing 1 changed file with 11 additions and 4 deletions.
15 changes: 11 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,13 @@ import { logger } from 'logixlysia'

const app = new Elysia({
name: 'Logixlysia Example'
}).use(logger())
}).use(
logger({
ip: false,
customLogMessage:
'🦊 {now} {level} {duration} {method} {pathname} {status} {message} {ip}'
})
)

app.listen(3000)
```
Expand All @@ -27,9 +33,10 @@ app.listen(3000)

### Options

| Option | Type | Description | Default |
| ------ | --------- | --------------------------------------------------------------------- | ------- |
| `ip` | `boolean` | Display the incoming IP address based on the `X-Forwarded-For` header | `false` |
| Option | Type | Description | Default |
| ------------------ | --------- | --------------------------------------------------------------------- | ------------------------------------------------------------------------- |
| `ip` | `boolean` | Display the incoming IP address based on the `X-Forwarded-For` header | `false` |
| `customLogMessage` | `string` | Custom log message to display | `🦊 {now} {level} {duration} {method} {pathname} {status} {message} {ip}` |

## `📄` License

Expand Down

0 comments on commit 6898832

Please sign in to comment.