[jQuery] An idea for a jQuery core addition - Plugin Registering...
Guys,
It occurred to me last night with the growing list of plug-ins and the fact
that so many plug-ins now are dependant on other plug-ins, that we should
try to add a couple of functions to the jQuery core for registering plug-ins
and detecting if a plug-in has been registered.
So, to register a plug-in, you'd add something like this to a plug-in:
$.plugin.register("autocomplete");
And then when writing a plug-in that's dependent on some other plug-in, you
could check for loaded plug-ins:
$.plugin.find(["dimension","blockui","below"]);
I'm just thinking that maybe the core library needs something to help
plug-in authors to manage the dependencies of their plug-ins--in order to
help developers using their plug-ins.
If we at least added a few core methods for tracking, we could expand the
architecture later if need be.
Does this make sense to anyone else?
-Dan