Strict CSP and nonce

Author: bivaldCreated Dec 7, 2021Updated Oct 3, 2025
Labelsenhancement

Hi,

I'm trying to use react-hot-toast (which looks amazing!) but I have a pretty strict CSP policy. I haven't found any mention of csp or nonce support in react-hot-toast. Looks like in the end it's goober that triggers the "Refused to apply inline style because it violates the following Content Security Policy directive... a nonce ('nonce-...') is required to enable inline execution." but I can't find any mention to CSP on goober either.

Anyone using CSP? I'm probably just missing something.

Also, let me know if you think this issue should be on goober and not hot toast :)

Regards, Niklas

Source: timolins/react-hot-toast