Support for manifest 3?
akaradzic-scribe opened this issue · comments
Hi,
We are using flagsmith in the web application and on the extension. So far everything was working great, but now we are migrating our extension to manifest v3 and I am getting the error ReferenceError: XMLHttpRequest is not defined
.
Are you planning to support manifest v3 or is there some workaround for this error?
We traced this error flagsmith-core.js.
In manifest v3 XMLHttpRequest
is not supported.
Hi @akaradzic-scribe - thanks for raising this issue - can you just confirm that you are only seeing ReferenceError: XMLHttpRequest is not defined
in a chrome extension? Is it just Chrome that is affected?
Hi @akaradzic-scribe, we've had cases like this before in other frameworks such as nuxt where xmlhttp / fetch isn't defined.
As a result, the SDK lets you provide a custom fetch implementation. I imagine you can just provide node-fetch as the implementation will solve your problem. An example of this is done here.
@kyle-ssg Thanks so much for your prompt response. This solved my problem. I suppose it would be very helpful for other folks if you updated your documentation with this information.
Noted, thank you for getting back to me @akaradzic-scribe, I'll keep this open and add some documentation today before I close this.