Hi Anne,

This is so much outside the reach of angular! A 304 means the server say's 
to the browser, there is no change in this file, you can use your cached 
version. They only way to get a 304 is when there is indeed a cached 
version, otherwise, the file would just get pulled, like every other 
resource. The only way to get an error is when the cached version of the 
resource is corrupted somehow.  As this all play's inside the internals of 
the browser, there is no way you can any influence on this using JS. 
The only other possible scenario is that the server gives a 304  in fault. 
that means the server tells the browser, nope, you should have this file, 
while it doesn't. I believe of the 2 this is the most likely thing to 
happen. However, as this is an error in the server, there is nothing you 
can do in JS again to fix this. 

However, you might be able to catch the error in JS, and retry the request. 
This has to be done outside AngularJS. I think the "easy" solution is to 
use a service-worker. Most browsers support those nowadays.

Regards
Sander

-- 
You received this message because you are subscribed to the Google Groups 
"Angular and AngularJS discussion" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to angular+unsubscr...@googlegroups.com.
To post to this group, send email to angular@googlegroups.com.
Visit this group at https://groups.google.com/group/angular.
For more options, visit https://groups.google.com/d/optout.

Reply via email to