Framework heads up: Fluid.js refactoring

Colin Clark colin.clark at
Fri Sep 19 17:49:34 UTC 2008

Hi everyone,

Just a heads up about some recent change happening in the framework.  
I'm working on FLUID-1077, pruning our core dependencies down in  
Fluid.js. Here are the details:

One of the side-effects of this pruning and refactoring is that the  
fluid namespace is now much flatter. I'll be removing the fluid.utils  
namespace altogether, moving most of its functionality directly into  
the core fluid object. My rationale here is that utility packages  
often become a catch-all for various bits of functionality that should  
be grouped or factored differently. If the utilities are essentially,  
they should be available at the top level. Otherwise, they should be  
encapsulated into a meaningful entity. Seem reasonable?

Other highlights from this refactoring:

* fluid.utils.derivePercentage() has been moved into the Uploader's  
private namespace.
* fluid.utils.debug() is now called fluid.log().
* fluid.utils.findForm() and seekNodesById() have been moved into  
* fluid.utils.escapeSelector() has been removed entirely, since it's  
now superceded by our use of jById and the component locate() function
* fluid.initDecorators() was been generalized into  
fluid.initSubcomponents() and removed
* fluid.createObjectForName() has been removed in favour of  
* fluid.delegateAfter() has been removed in favour of the events system

There's lots more to come, so I'll keep you up to date as the changes  
roll in before code freeze. Feedback or questions are welcome.


Colin Clark
Technical Lead, Fluid Project
Adaptive Technology Resource Centre, University of Toronto

More information about the fluid-work mailing list