2***@qq.com
2***@qq.com
  • 发布:2024-12-17 16:56
  • 更新:2024-12-17 16:56
  • 阅读:116

鸿蒙harmony next 使用PDF.js预览文件报错跨域怎么解决

分类:uni-app

使用的是PDF.js插件预览(web-view :src=xxx),安卓没有问题,鸿蒙报错

"Access to fetch at 'https://xxxxxxxxxxxxxxxxxxxx' from origin 'null' has been blocked by CORS policy: No 'Access-Control-Allow-Origin' header is present on the requested resource. If an opaque response serves your needs, set the request's mode to 'no-cors' to fetch the resource with CORS disabled.",页面显示Message:Failed to fetch
src直接使用网络地址不用pdf.js可以浏览文件,但浏览页面全屏显示,无法控制样式
想问问各位大佬这个怎么解决?

2024-12-17 16:56 负责人:无 分享
已邀请:

要回复问题请先登录注册