我有一个返回 JSON 的 url,但返回字符串的开头是
])}while(1);</x>{"success":true,"payload":{"value":
我想拆分])}while(1);</x>并查看该split数组的 [1] 值。
现在我在做
fetch(jsonURL)
.then(res => {
console.log(res);
});
通常我会在,console.log但我收到以下错误:
the-myth-of-the-genius-programmer-9381a884591e:1 Uncaught (in promise) SyntaxError: Unexpected token ] in JSON at position 0
精慕HU
相关分类