It seems like inevitable to me too, Dan.  

If for example, $.plugin.find(["dimension","blockui","below"]);  fails, it
would output a message "Error: plugin <plugin_name> requires
<other_plugin_name>". 

-----Original Message-----
From: jquery-en@googlegroups.com [mailto:[EMAIL PROTECTED] On
Behalf Of Dan G. Switzer, II
Sent: lundi 30 avril 2007 21:50
To: jquery-en@googlegroups.com
Subject: [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

Ce message Envoi est certifié sans virus connu.
Analyse effectuée par AVG.
Version: 7.5.467 / Base de données virus: 269.6.2/780 - Date: 29/04/2007
6:30
 

Reply via email to