Open THGAmanowski opened 2 years ago
Hi, the cors is probably coming from your vite dev server. Check your svelte config and look for a cors setting, may be you have something there?
Hi, the cors is probably coming from your vite dev server. Check your svelte config and look for a cors setting, may be you have something there?
Thanks for the quick reply! I'm not entirely sure where I'd be looking for such a config. The only things we have are rollup configs.
these are usually in the svelte.config.js, are you using a standard project or do you bundle with rollup yourself with custom configuration?
Here is the link to svelte vite config from the docs:
It's a shareable web component library, so we have some rollup configs we've added, a Form.wc.svelte component and a App.svelte for demoing of this component. We don't have a svelte vite config.
I've managed to get the captcha working on the demo if I put it in App.svelte - but as soon as it's in the Form.wc.svelte web component and I include that component in App.svelte I get the cors error.
Hello!
Having some issues using the re-captcha in my svelte app. I manage to get the ready state to fire, but then all I get is this error:
Has anyone seen this before? I've tried adding the captcha as a div I render on it's own but I get the same issue in the end.
Does it need to be hosted on a web server rather than just localhost? Not sure why it would work for others.