I am trying to get the data-role value from an object and multiply that objects width and height with that value.
Here is a fiddle of what I have so far http://jsfiddle.net/kq7mA/
Please help if you can 🙂
var cssStyle = {
'background-color' : '#ddd',
'font-weight' : 'bold',
'width' : ('100px' * data-role),
'height' : ('150px' * data-role),
'color' : 'white'
}
$(document).ready(function() {
$('li').css(cssStyle);
});
http://jsfiddle.net/kq7mA/2/