Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Select an option

  • Save akirchmyer/7508829 to your computer and use it in GitHub Desktop.

Select an option

Save akirchmyer/7508829 to your computer and use it in GitHub Desktop.
A Pen by Andrew Kirchmyer.
<h2>inline: a-tags are inline by default. You cannot set a height or a width.</h2>
<p>
<a class="inline">Inline</a>
<a class="inline">Inline</a>
<p>
<h2>Inline-block: Same line, can set height and width.</h2>
<p>
<a class="inline-block"></a>
<a class="inline-block"></a>
<p>
<h2>
Block: Different lines, can set height and width.</h2>
<a class="block"></a>
<a class="block"></a>
a {
height: 100px;
width: 100px;
margin: 5px;
background-color: LightSeaGreen;
}
.inline {
height: 100px;
width: 100px;
}
.inline-block {
display: inline-block;
}
.block {
display: block;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment