The event binding is based on .data, so that should work just as well.
Though there isn't really much reason to do it, as the point of data
is to avoid adding JS objects to DOM elements. If deal with JS objects
only, don't bother using data, just add it directly.
Jörn