Skip to main content
CSS-Tricks
  • Articles
  • Notes
  • Links
  • Guides
  • Almanac
  • Picks
  • Shuffle
Search

Articles Tagged
trick

5 Articles
{
,

}
Image
Direct link to the article Cool Little CSS Grid Tricks for Your Blog
grid trick

Cool Little CSS Grid Tricks for Your Blog

I discovered CSS about a decade ago while trying to modify the look of a blog I had created. Pretty soon, I was able to code cool things with more mathematical and, therefore, easier-to-understand features like transforms. However, other areas …

Image
Ana Tudor on Jun 9, 2020 Updated on Jul 19, 2020
Image
Direct link to the article DRY State Switching With CSS Variables: Fallbacks and Invalid Values
calc css variables custom properties trick

DRY State Switching With CSS Variables: Fallbacks and Invalid Values

This is the second post in a two-part series that looks into the way CSS variables can be used to make the code for complex layouts and interactions less difficult to write and a lot easier to maintain. The first …

Image
Ana Tudor on Dec 6, 2018
Image
Direct link to the article DRY Switching with CSS Variables: The Difference of One Declaration
css variables custom properties trick

DRY Switching with CSS Variables: The Difference of One Declaration

This is the first post of a two-part series that looks into the way CSS variables can be used to make the code for complex layouts and interactions less difficult to write and a lot easier to maintain. This first …

Image
Ana Tudor on Dec 5, 2018 Updated on Dec 6, 2018
Image
Direct link to the article Making Magic with WebSockets and CSS
magic trick

Making Magic with WebSockets and CSS

Ooo. Ooo. It’s a trick, that uses CSS.…

Image
Chris Coyier on Jan 18, 2017
Image
Direct link to the article Aligning Text Smartly in CSS
text-align trick

Aligning Text Smartly in CSS

One of those bonafide CSS tricks. Vijay Sharma shows it’s possible to center align a single line of text, but if it wraps, left align the text. A small adjustment, but little tricks like this can help legibility.…

Image
Robin Rendle on Apr 13, 2016

CSS-Tricks is powered by DigitalOcean.

Keep up to date on web dev

with our hand-crafted newsletter

DigitalOcean
  • About DO
  • Cloudways
  • Legal stuff
  • Get free credit!
CSS-Tricks
  • Contact
  • Write for CSS-Tricks!
  • Advertise with us
Social
  • RSS Feeds
  • CodePen
  • Mastodon
  • Bluesky
Back to Top
Advertisement