Content Security Policy and Live Feedback on vercel.com #56562
SummaryI am introducing CSP for a next.js app (version 13.4.12) deployed on vercel.com. But sadly the vercel live feedback script (https://vercel.live/_next-live/feedback/feedback.js) is not being loaded correctly, as in the For reference I get this error messages: And thus: Thank you very much! Additional informationNo response ExampleYou can find an example here: https://with-strict-6b50yj4wz-holgergp.vercel.app/ This is a preview deployment (that contains the feedback capability) of this repo https://github.com/holgergp/with-strict-csp and this PR https://github.com/holgergp/with-strict-csp/pull/1 |
Replies: 3 comments 4 replies
|
i'm having the same problem with next v13.5.4 :/ - have you find any solution for this? |
|
i found a way to fix this based on Vercel docs, i'm using this function to create CSP headers and update the request headers in next.js middleware: |
|
Here is what I use for Vercel Live: I just went through and ensured this is the minimal set of required domains.
Every service that makes external requests really needs to simply post a CSP string like the one above for you to easily integrate into your service. This is how I manage CSPs: https://gist.github.com/danthedaniel/cadcaa74888e79d954a7ac403ad41c33 |


I found the solution here: https://vercel.com/docs/workflow-collaboration/comments/specialized-usage