[ 14 posts ] Go to page Previous1, 2

Eric Ferraiuolo

YUI Developer

  • Username: ericf
  • Joined: Mon Jan 12, 2009 8:26 pm
  • Posts: 380
  • Location: Boston, MA
  • Twitter: ericf
  • GitHub: ericf
  • Gists: ericf
  • IRC: eric_f
  • YUI Developer
  • Offline
  • Profile

Re: YUI [combo] Loading Strategy?

Post Posted: Fri Jun 05, 2009 11:52 am
+0-
Interesting Dav, so the filter function(s) are ran over the resulting URI? I wasn't sure at which part in the process that happened…

I'll look-into apply this sort of thing like how you have it.

It would be nice to have the separator an explicit configuration property, as it would be nice to some of the default filters like: DEBUG and RAW, and not have it interfere.
Eric Ferraiuolo

Eric Ferraiuolo

YUI Developer

  • Username: ericf
  • Joined: Mon Jan 12, 2009 8:26 pm
  • Posts: 380
  • Location: Boston, MA
  • Twitter: ericf
  • GitHub: ericf
  • Gists: ericf
  • IRC: eric_f
  • YUI Developer
  • Offline
  • Profile

Re: YUI [combo] Loading Strategy?

Post Posted: Mon Jan 11, 2010 11:46 pm
+0-
Bumping-up this topic again...

I'm curious if any of the work for 3.1 (specifically around the 'patterns') could support multiple combo-bases?

As I'm adding custom modules to my project, I'm adding HTTP requests. I can support combo-handling my own modules from my own server; configuring the Loader to know about my combo-hanlding root could help me greatly reduce these extra HTTP requests.

I've been following the work on Loader with 'patterns'. I'm curious how it's going to be used with the Gallery? And if this could be leveraged to support multiple combo-bases?
Eric Ferraiuolo

hame25

  • Joined: Thu Apr 26, 2012 5:34 am
  • Posts: 35
  • Offline
  • Profile

Re: YUI [combo] Loading Strategy?

Post Posted: Fri Oct 19, 2012 12:44 pm
+0-
Quote:
#1 ------:
I think we can tackle this defining a "lazyload" feature per YUI instance. So at the moment you create a new instance, defining new modules and using "use" to load the requirements, the system should wait a little bit before actually inserting the script tag in the page, just to make sure that the next block is not another instantiation process. If it's in fact another instance, we can merge the requirements, inserting a single script tag, instead of 2, and so on. I guess the first step should be delaying the loading process until the "domready" or "load". Merging all the initial instances thru a single script tag instead of 19 scripts tags. Here is an example:

YUI({modules: {a:{fullpath:'a.js'}}}).use ('a', 'node', 'io', function(Y) {});

...HTML CODE IN THE MIDDLE...

YUI({modules: {b:{fullpath:'b.js'}}}).use ('b', 'dd', 'event', function(Y) {});

The optimized result should be:
1. yui.js
2. combo?node+event+io+dd+other
3. a.js
4. b.js

instead of:
1. yui.js
2. combo?node-io-other
3. a.js
4. combo?event-dd-other
5. b.js

One of my side projects (bootstrap: http://github.com/caridy/bootstrap/tree/master) will address some of this issues, wrapping he loader functionality, and providing a similar API for yui 2.x as well. Feel free to dig in.


Just come across this and wondered if there was any progress made on this?, a limitation of loader is the number of requests made for each use(). So at the moment static loading seems favourable

Caridy Patino

YUI Contributor

  • Username: caridy
  • Joined: Mon Dec 08, 2008 5:40 pm
  • Posts: 491
  • Location: Miami, FL
  • Twitter: caridy
  • GitHub: caridy
  • Gists: caridy
  • IRC: caridy
  • YUI Developer
  • Offline
  • Profile

Re: YUI [combo] Loading Strategy?

Post Posted: Fri Oct 19, 2012 2:05 pm
+0-
I don't know if the new "delayUntil" configuration will help with this or not:

http://yuilibrary.com/yui/docs/api/clas ... delayUntil

I don't think the loader is that smart, and each "use" statement is treated separately, but I might be wrong.
  [ 14 posts ] Go to page Previous1, 2
Display posts from previous:  Sort by  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum