I got some aspect ratio value in a data-attribute like
<li data-ratio="4/3">4:3</li>
On a click I need to get the correct value - not the string, like I get it with this:
'click li': function(event) {
var ratio = $(event.currentTarget).attr('data-ratio');
}
I don't know if I have to change the format of the data-attribute or just do some convertion on the result - like:
var value = $(event.currentTarget).attr('data-ratio').split('/');
ratio = value[0] / value[1];