Default anchor styles
I used to write a base style for anchors
a {
text-decoration: underline;
color: #aaaaaa;
}
And then override any special cases. But since I started using a
tags forblock-level links (think tiles), I'm finding it better to approach it with the following method:
a {
text-decoration: none;
color: inherit;
}
p a {
text-decoration: underline;
color: #aaaaaa;
}
Alternatively, use a reset class on links that you don't want to be styled e.g.
a {
text-decoration: underline;
color: #aaaaaa;
}
a.r {
text-decoration: none;
color: inherit;
}
Let me know if you think this is useful!
Written by David Smith
Related protips
Have a fresh tip? Share with Coderwall community!
Post
Post a tip
Best
#Css
Authors
Related Tags
#css
Sponsored by #native_company# — Learn More
#native_title#
#native_desc#