add no-cors
This commit is contained in:
parent
82e338147e
commit
f94b3cf6e3
1 changed files with 3 additions and 1 deletions
|
@ -46,7 +46,9 @@ A._Collection.prototype.html = function (html) {
|
||||||
};
|
};
|
||||||
|
|
||||||
A._Collection.prototype.load = async function (url) {
|
A._Collection.prototype.load = async function (url) {
|
||||||
const res = await fetch(url);
|
const res = await fetch(url, {
|
||||||
|
mode: 'no-cors'
|
||||||
|
});
|
||||||
if (!res.ok) {
|
if (!res.ok) {
|
||||||
console.error(`load(${url}) failed with code ${res.status}`);
|
console.error(`load(${url}) failed with code ${res.status}`);
|
||||||
return;
|
return;
|
||||||
|
|
Loading…
Reference in a new issue