On Sun, Jul 05, 2009 at 05:13:39AM -0700, Mackram wrote: > > Okay top of my head thinking will lead me to do the following > algorithim: > > 1- Before returning the JSON response check if the script or > stylesheet is already in the page-dependencies if it is eliminate the > script/stylesheet from being sent since the bundle has already > included it > 2- By adding a js function on the client side we can check the json > response and if the stylesheet/script has already been added then do > not add it again. > > The above will make sure that in webpages that are heavy in both css & > javascript (much of Web 2.0) we do not keep requesting the client to > reload the same page and more importantly global variables/functions > are not over-written. > > What do you think? Should I go ahead and implement this?
I think that the penalty isn't that high since CSS and JS files should always be cached anyway. But it would be much cleaner with your proposal, plus a bit more efficient especially when one does have external files without cache time. So it would be cool indeed if you enhanced this mechanism. Leslie --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "weblocks" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/weblocks?hl=en -~----------~----~----~----~------~----~------~--~---
