I am using html5 data attributes to store data like target dom and initialize events with jQuery delegation method.
For example,
<a href="#" data-target="#target" data-action="/update">edit</a>
which means clicking it enables editing of #target and will send updating request to /update through ajax call.
I am wondering whether this is in good style and has some potential problems.
Thanks a lot.
It’s totally fine to use custom attributes in HTML. I haven’t encounter any issues with this approach in any browsers (including IE6)