Skip to content

Conversation

@gordyr
Copy link

@gordyr gordyr commented Jul 9, 2012

Two main changes:-

  1. Hides fragment until all CSS files added via the "addCss" method are loaded. from my apps homepag
  2. Simple resource management - Keeps a log of add JS/CSS files and checks against them before loading them. This is very useful when dynamically loading fragments via ajax calls in order to prevent repeated http requests.

e.g. When navigating from my applications 'welcome' page to 'user control panel' only a single fragment needs to be updated rather than a full page load. Therefore I perform an ajax request to get the html of the required fragment. With the above changes, the response of this request was reduced down to around 200ms from about 800ms. You can now essentially specify all required resources needed to render a fragment without repeating requests under any circumstance (ajax request or full page load).

NOTE: Please look at the full file from the latest 'commit' as it took me a while to get to grips with the way pull requests work in github. My apologies.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant