i very often see code like this:
jQuery('#aslkdjf').css({top:2+'px'});
can i get rid of the:
+'px'
? Or do i have to configure the default unit of those values?
Any official documentations?
Even the Community isnt sure in this case: The first comment of the user “piki” on the page http://api.jquery.com/css/ suggest that sometimes mm are used, sometimes px are used.
Piki’s question even have 55 upvote’s (my post isnt a try to get upvoted too 8D)
As Rob W wrote,
a look on the sourcecode (http://james.padolsey.com/jquery/#v=git&fn=jQuery.style) is the solution.
Scott Evernden and jamis0n are right too.