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
-[How do I set both `Content-Security-Policy` and `Content-Security-Policy-Report-Only` headers?](https://github.com/helmetjs/helmet/issues/351#issuecomment-1015498560)
13
13
-[How should I use Helmet with non-document responses?]({{< ref "faq/non-documents" >}})
14
14
-[How do I disable blocking with the `X-XSS-Protection` header?]({{< ref "faq/x-xss-protection-disable-blocking" >}})
15
+
-[How do I enable the `report` directive with the `X-XSS-Protection` header?]({{< ref "faq/x-xss-protection-report-directive" >}})
15
16
-[Who made Helmet?]({{< ref "faq/contributors" >}})
title: How do I enable the "report" directive with the X-XSS-Protection header?
3
+
---
4
+
5
+
Previous versions of Helmet (and the `x-xss-protection` package) allowed you to add the `report` directive. This functionality was removed because enabling this header is no longer recommended.
6
+
7
+
If you still need to set a `report` directive for some reason, you can write your own small middleware:
0 commit comments