An open API service indexing awesome lists of open source software.

https://github.com/edvardchen/on-head

Hook before http response send head
https://github.com/edvardchen/on-head

Last synced: 11 months ago
JSON representation

Hook before http response send head

Awesome Lists containing this project

README

          

# on-head

Hook before http response send head

## Install

```bash
npm i on-head
```

## Usage

```typescript
import Express from 'express';

const app = Express();
app.use((req, res, next) => {
onHead(res, () => {
// You still can modify response headers
res.setHeader('tracer-id', '1234');
});
next();
});
```