Is there any performance difference between:
p {
margin:0px;
padding:0px;
}
and omitting the final semicolon:
p {
margin:0px;
padding:0px
}
Thanks in advance!
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
No there is not, the browser doesn’t care about the trailing semicolon, even in IE6. The parser checks for it as a delimiter that’s it.
If anything, since the browser is basically performing tokenization not much more complex than
.split(';'), the second may be faster in a probably not measurable way simply because of the lack of an extra null token. But…the difference would be infinitesimal, and you do not need to worry about it either way.