You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+8
Original file line number
Diff line number
Diff line change
@@ -66,6 +66,14 @@ fastify.register(
66
66
{ threshold:2048 }
67
67
)
68
68
```
69
+
### customTypes
70
+
[mime-db](https://github.com/jshttp/mime-db) is used to determine if a `Content-Type` should be compressed. You can compress additional content types via regular expression.
71
+
```javascript
72
+
fastify.register(
73
+
require('fastify-compress'),
74
+
{ customTypes:/x-protobuf$/ }
75
+
)
76
+
```
69
77
### Brotli
70
78
Brotli compression is not enabled by default, if you need it we recommend to install [`iltorb`](https://www.npmjs.com/package/iltorb) and pass it as option.
0 commit comments