Skip to content

Instantly share code, notes, and snippets.

@crixlet
Created December 8, 2013 01:19

Revisions

  1. crixlet created this gist Dec 8, 2013.
    1 change: 1 addition & 0 deletions new_gist_file_0
    Original file line number Diff line number Diff line change
    @@ -0,0 +1 @@
    This isn't very hard. Just give the list centered text (e.g. ul.nav { text-align: center; }) and the list items inline-block (e.g. ul.nav li { display: inline-block; }). If you want to do it with margin for whatever reason, look into width: fit-content; (link).