我正在为我的颤振网络项目实现recaptcha v3,
Access to XMLHttpRequest at 'https://www.google.com/recaptcha/api/siteverify' from origin 'http://localhost' has been blocked by CORS policy: Response to preflight request doesn't pass access control check: No 'Access-Control-Allow-Origin' header is present on the requested resource.
我已经在设置中添加了本地主机,是否需要做其他设置才能解决这个问题?
发布于 2022-06-14 16:11:21
就像堆叠溢出响应一样,flutter-web-cors-problem-solution说,下面的内容对我来说很好;
1-转到flutter\bin\cache并删除一个名为: flutter_tools.stamp的文件
2-转到flutter\packages\flutter_tools\lib\src\web并打开文件chrome.dart。
3-找到‘-禁用-扩展’
4-添加“禁用-网络-安全”
https://stackoverflow.com/questions/72620091
复制相似问题