New issue
Advanced search Search tips

Issue 850099 link

Starred by 2 users

Issue metadata

Status: WontFix
Owner: ----
Closed: Jun 2018
Components:
EstimatedDays: ----
NextAction: ----
OS: Mac
Pri: 2
Type: Bug



Sign in to add a comment

preload as fetch loads resources twice

Reported by nathan.m...@gmail.com, Jun 6 2018

Issue description

UserAgent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_13_3) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/66.0.3359.181 Safari/537.36

Steps to reproduce the problem:
1. Add a `<link rel="preload" as="fetch" href="some.json" />`
2. Attempt to `fetch("some.json")`

What is the expected behavior?
The resource should be loaded once

What went wrong?
The resource was loaded twice

Did this work before? No 

Does this work in other browsers? N/A

Chrome version: 66.0.3359.181  Channel: stable
OS Version: OS X 10.13.3
Flash Version: 

I believe it is related to this issue (https://bugs.chromium.org/p/chromium/issues/detail?id=652228) which seems to be fixed, however as you can see - the resource is loaded twice.

Simple example here: http://nathanmahdavi.com/double-fetch
 
Screen Shot 2018-06-06 at 16.00.32.png
189 KB View Download
Components: Blink>Loader Blink>Network>FetchAPI
Labels: Needs-Triage-M66
Status: WontFix (was: Unconfirmed)
crossorigin attribute is missing.
Even when defining crossorigin it still will fetch the resource. Chrome believes they are different types.

http://nathanmahdavi.com/double-fetch/cors-annon.html
http://nathanmahdavi.com/double-fetch/cors-auth.html
Please specify {credentials: "same-origin"} for crossorigin="anonymous". 
That did work. I researched quite a lot regarding this and didn't find any information on needing a cross origin policy.

Thank you for pointing me in the right direction.

Sign in to add a comment