I’ve been trying to compile a wasm code on the frontend javascript but this error has been bugging me for hours now:
Uncaught (in promise) CompileError: WebAssembly.compile(): Refused to compile or instantiate
WebAssembly module because 'unsafe-eval' is not an allowed source of script in the following
Content Security Policy directive: "script-src 'self'"
at p (index-d10505ae.js:69:52328)
at 2../src/bn128.js (index-d10505ae.js:53:92638)
I’ve added meta
tag such as <meta http-equiv="Content-Security-Policy" content="script-src 'self' 'unsafe-eval';">
but i still got it.