Last Updated: February 25, 2016
· nell

Remove extra spacing from li {display:inline-block}

There are two ways to remove extra spacing from lists with li {display:inline-block}:

a) Remove any white space between the list elements (which gives you ugly, unreadable code)

b) Give the list a font-size of 0 and then reset the font-size for the list elements:
ul {font-size:0}
li {font-size:14px}

You should use absolute units such as pixels, as em are relative to the parent element's font size.