This function works as a shortcut of one of the calls:
getAttrValue(element, attrName).toNumber()
or
getAttrValue(attrName).toNumber()

See Also:

getAttrValue(), toNumber()