【发布时间】:2021-03-09 08:09:48
【问题描述】:
我已经压缩并在 s3 中有 gz 文件。在这里,https://oic-accounts.s3.ap-south-1.amazonaws.com/3d-try-json-files/gzip/3.json.gz
但是当我尝试使用loader.load("https://oic-accounts.s3.ap-south-1.amazonaws.com/3d-try-json-files/gzip/3.json.gz", onLoadModel, this.xhrPercentage);加载threejs时
它不工作并抛出VM4245:1 Uncaught SyntaxError: Unexpected token in JSON at position 0这个错误。
P.S:上传的gzip文件content type是application/json
感谢您的宝贵阅读和回答:)
【问题讨论】:
-
打开 URL 时,我看到一条
Access Denied错误消息。如果权限定义正确,您应该检查您的 AWS 后端。 -
想一些授权。我不知道。但我从 slack 那里得到了解决方案
标签: javascript json reactjs amazon-s3 three.js