Fix for #2384 and caching enabled with modifyVars set#2735
Merged
matthew-dean merged 3 commits intomasterfrom Jan 26, 2016
Merged
Fix for #2384 and caching enabled with modifyVars set#2735matthew-dean merged 3 commits intomasterfrom
matthew-dean merged 3 commits intomasterfrom
Conversation
…tyles are done / The actual XHR requests are changed to async for a speed boost for "sync" loading of orders of magnitude
- Basically, compares assigned vars to vars in localStorage. If they match (and all the other cache criteria pass), then loads from cache
Member
Author
|
Any comments on this? Any reason not to merge it? |
matthew-dean
added a commit
that referenced
this pull request
Jan 26, 2016
Fix for #2384 and caching enabled with modifyVars set
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This came up for me on a project where there are "cobranded" versions of the same site. I decided to try rendering the cobranding CSS in the browser, which is when I discovered cache was automatically turned off if modifyVars were set at all. So, I added caching with custom vars.
I also wanted the page rendering to be blocked until styles were done, but was having the same issue as #2384. Since "sync" rendering took 7-8 seconds and "async" rendering took about half a second, I decided to fix this. Not sure if docs should be updated to reflect that XHR is always async. What's nice about this is that the default value should make everything a zillion times faster for people using Less in the browser.