Hi,

> The easiest way of fixing this would be
> to rename stuff like 'click' to 'onclick' - that would remove all
> namespace collisions. Back when jQuery was first released, all events
> were mapped to 'onclick' - but I changed this so that backwards
> support with Prototype would be easier.
>
> This would obviously be a big API change, no matter which way we
> decide to spin it.

Well, you could keep the old functions for a while but take them out of the 
documentation. Then people have time to switch to the new API whithout 
immediatelly breaking their old code. Maybe you move them into a plugin.

> > The ambiguity could be avoided by forcing the user to use bind(),
> > unbind() and trigger(). A reliable solution, but not very sexy.
>
> Forcing is definitely not an option. Splitting off into external
> plugins is much more realizable.

Generally I don't like the idea of just having bind() unbind() and trigger(). 
How about having names like onclick(), noclick() and doclick()? The on- 
function binds an event handler, the no- function unbinds it an the do- 
function triggers the event.

The names don't necessarily be that way. I just thought of names that would 
not collide like unload().

Christof

_______________________________________________
jQuery mailing list
[email protected]
http://jquery.com/discuss/

Reply via email to