This repository was archived by the owner on Apr 10, 2025. It is now read-only.
This repository was archived by the owner on Apr 10, 2025. It is now read-only.
defer_javascript should turn off for requests with header XMLHttpRequest #480
Closed
Description
From amattie@gmail.com:
I think defer_javascript should automatically disable when the request contains
a "X-Requested-With: XMLHttpRequest" header or a "Origin" header w/ any value.
The reasoning is that any content placed on the page by XmlHttpRequest will
have the expectation that the script will run as soon as it's on the page; in
the current implementation, those script tags don't appear to run at all.
Like I said earlier, defer_javascript looks very promising and we're excited to
eventually be able to use it. It appears to speed up rendering significantly; I
wouldn't have bothered with investigating issues otherwise!
Original issue reported on code.google.com by jmara...@google.com
on 27 Jul 2012 at 9:50