Skip to content

Commit bb8e453

Browse files
committed
Update README
1 parent a1df576 commit bb8e453

File tree

1 file changed

+9
-0
lines changed

1 file changed

+9
-0
lines changed

README.md

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -183,6 +183,15 @@ The followings are built-in mappings:
183183
| webm | video/webm | zip | application/zip |
184184
| mp3 | audio/mp3 | wasm | application/wasm |
185185

186+
### File request handler
187+
188+
```cpp
189+
// The handler is called right before the response is sent to a client
190+
svr.set_file_request_handler([](const Request &req, Response &res) {
191+
...
192+
});
193+
```
194+
186195
NOTE: These static file server methods are not thread-safe.
187196

188197
### Logging

0 commit comments

Comments
 (0)