Skip to content

Instantly share code, notes, and snippets.

@rzvl
Created June 25, 2021 17:12
Show Gist options
  • Save rzvl/a295374dd6acb893c88bc61146bc872b to your computer and use it in GitHub Desktop.
Save rzvl/a295374dd6acb893c88bc61146bc872b to your computer and use it in GitHub Desktop.
Minimal Table Styles from MDN
html {
font-family: sans-serif;
}
table {
border-collapse: collapse;
border: 2px solid rgb(200,200,200);
letter-spacing: 1px;
font-size: 0.8rem;
}
td, th {
border: 1px solid rgb(190,190,190);
padding: 10px 20px;
}
th {
background-color: rgb(235,235,235);
}
td {
text-align: center;
}
tr:nth-child(even) td {
background-color: rgb(250,250,250);
}
tr:nth-child(odd) td {
background-color: rgb(245,245,245);
}
caption {
padding: 10px;
}
@rzvl
Copy link
Author

rzvl commented Jun 25, 2021

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment