I have written some relatively simple jQuery plug-ins, but I am contemplating writing something more advanced in order to keep commonly used methods on the site easily accessible and DRY
For example, I might have something like this for a structure:
plugin - popup - element ... === popup === - login - product ... === element === - shoppingCart - loginStatus ...
So, to bind a popup login popup event, I'd like to be able to do: $('#login_button').plugin.popup.login();
What's the best way to do this? Is there a better way of achieving what I want to do?
Cheers,