Let's say you have a resource, could be an image, could be jQuery from a cdn. This resource is hosted at some 3rd party url, like https://example-cdn.com/resource.ext
. Let's also assume it is cacheable (whatever that means--let me know if that is a non-trivial detail).
When https://website-a.com
requests the resource (let's assume it was included in the html directly), it takes some time to load, but then the browser caches it for faster load next time.
Now, https://website-b.com
is also including that resource in its html, using the exact same url (https://example-cdn.com/resource.ext
).
My question is this: will the browser reach for the cached resource (because it was already fetched while loading https://website-a.com
), or is there some reason that it would not be able to find it in the cache and have to load it over the network all over again?
Edit: This stackexchange answer seems to contain some related information. Can anyone verify that this answer is correct in all its assertions about caching? https://webmasters.stackexchange.com/a/84685