I have to use YUI3 for this particular project. Yes i know YUI is dead.
How does one return a number of notes based on the data attributes wildcard?
E.g.
Y.all('[data-test="*"]').size() > 0
I've set up a JSBin if you need a further example: http://jsbin.com/hupip/edit
Can you not use:
Y.all('[data-target]');
?
This should select all elements with data-target attribute regardless of its value, the code you posted would select elements with an empty value