CSS Reset 2.5Reset your CSS to start off on the right foot ;)

The original code has been written by Eric Meyer but since it has not been updated for almost 3 years, I’ve decided to regularly update it here.

  • Version 2.1 : + textarea { resize: none; } to avoid textarea resizing. (08/10/2013)
  • Version 2.2 : + a { outline: none; } to avoid dots around links. (02/12/2013)
  • Version 2.3 : I implemented many stuff from YUI 3.5.0 reset.css. (03/12/2013)
  • Version 2.4 : + body { -webkit-font-smoothing: antialiased; } to avoid aliasing on Chrome. (21/01/2014)
  • Version 2.5 : + a { color: inherit; text-decoration: none; } to avoid links auto-formatting. (28/01/2014)

To use it through from Google Code CDN, just add this line in your HTML head :

<link href="//ig-css-reset.googlecode.com/git/reset.css" rel="stylesheet" type="text/css">

And here is the source code :

/*
  Ivan Gabriele : http://www.ivangabriele.com/css-reset/
  v2.5 | 20140128
  License: none (public domain)
*/

html{
  color: #000;
  background: #fff;
}
html, body, div, span, applet, object, iframe,
h1, h2, h3, h4, h5, h6, p, blockquote, pre,
a, abbr, acronym, address, big, cite, code,
del, dfn, em, img, ins, kbd, q, s, samp,
small, strike, strong, sub, sup, tt, var,
b, u, i, center,
dl, dt, dd, ol, ul, li,
fieldset, form, label, legend,
input, select, textarea,
table, caption, tbody, tfoot, thead, tr, th, td,
article, aside, canvas, details, embed,
figure, figcaption, footer, header, hgroup,
menu, nav, output, ruby, section, summary,
time, mark, audio, video {
  margin: 0;
  padding: 0;
  border: 0;
  font-size: 100%;
  font: inherit;
  vertical-align: baseline;
}
article, aside, details, figcaption, figure,
footer, header, hgroup, menu, nav, section {
  display: block;
}
a {
  color: inherit;
  outline: none;
  text-decoration: none;
}
blockquote, q {
  quotes: none;
}
blockquote:before, blockquote:after,
q:before, q:after {
  content: '';
  content: none;
}
body {
  -webkit-font-smoothing: antialiased;
  line-height: 1;
}
caption, th {
  text-align: left;
}
fieldset, img {
  border: 0;
}
legend {
  color: #000;
}
ol, ul {
  list-style: none;
}
sub {
  vertical-align: text-bottom;
}
sup {
  vertical-align: text-top;
}
table {
  border-collapse: collapse;
  border-spacing: 0;
}
textarea {
  resize: none;
}

Leave a Reply

Your email address will not be published. Required fields are marked *

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>