Custom Selectors for Plugins

Custom Selectors for Plugins


On the jquery-ui list, someone asked how they can tell if a plugin has
already been initialized on an element. They're currently using class
detection, e.g., .is('.ui-dialog-content') but wondering if there's a
better way.
Right now I think the most reliable method is .is(':data
(pluginName)'), but I'd like to suggest adding custom selectors to all
the widgets and interactions like we had in previous versions: .is
(':ui-pluginName'). This could even be done through $.widget to
prevent us from having to do this in each plugin.
Thoughts?
original thread: http://groups.google.com/group/jquery-ui/browse_thread/thread/88800038d0e25df8