Best of CSS — April 2024
- 1
- 2
Community Picks·2y
Learn CSS, HTML and JavaScript by Playing Coding Games
Learn CSS, HTML, and JavaScript by playing coding games in an engaging and interactive environment. Traditional learning methods lack practice, engagement, and can be boring. By combining practice and an interactive learning environment, you can make learning to code more efficient, interesting, and fun.
- 3
Atomic Spin·2y
5 Tailwind CSS Anti-Patterns to Avoid
Tailwind CSS has been a game-changer for developers, but there are anti-patterns to avoid when working with it. Avoid relying solely on the built-in color palette, under-utilize theme customization, and use a component-based framework. Additionally, avoid using the `@apply` directive and using Tailwind in domain-level components.
- 4
- 5
- 6
- 7
- 8
- 9
Hacker News·2y
Hidden Gems of Tailwind CSS
Tailwind CSS offers hidden gems like changing radio/checkbox colors, using the peer-modifier, styling file inputs, changing color opacity, combining font-size and line-height, using pointer events, truncating multi-line text, creating square elements, highlighting text, styling named groups, adding custom variants, and using arbitrary values.
- 10
- 11
- 12
Community Picks·2y
CSS Grid vs. Flexbox: Which Should You Use and When?
Flexbox and CSS Grid are two CSS layout modules that allow for the creation of complex layouts. Flexbox is suitable for content flow and flexibility, while CSS Grid focuses on precise content placement and allows for two-dimensional layouts. The choice between the two depends on the specific requirements of each layout.
- 13
- 14
Theo - t3․gg·2yThe Correct Base Font Size
This post discusses the ideal base font size, the advantages of using relative units for font sizes, and offers tips for making text fields more usable and accessible. It also highlights the importance of respecting user preferences and following WCAG standards.
- 15
- 16
- 17
asayer·2y
Exploring Atomic CSS: A Scalable Architecture for Modern Web Development
Learn about Atomic CSS, a scalable architecture for modern web development that uses small, single-purpose classes. Discover the advantages of implementing Atomic CSS, such as improved code organization, scalability for large projects, performance optimization, and enhanced collaboration. Find out how to avoid common pitfalls when using Atomic CSS.
- 18
Community Picks·2y
No more dreadful dropdowns — long live Popover!
Firefox has released support for the Popover API, making it easier to create components like dropdowns, toasts, and dialogs without the need for Javascript. The Popover API allows elements to pop over existing content and comes with a new CSS feature called Top layer that simplifies styling and control.
- 19
DEV·2y
Earth rescue - A CSS only game
A CSS-only game created for the Frontend Challenge, inspired by Earth Day. Includes information on generating waves in CSS, using the BEM Pattern for CSS, creating an earth design with CSS grid, improving CSS animations for performance, and using checkboxes to control game state. The game features icons for ecological disasters and a CSS robot companion.
- 20
- 21
LogRocket·2y
Mojo CSS vs. Tailwind: Choosing the best CSS framework
CSS frameworks like Tailwind and Mojo CSS offer different features and benefits. Tailwind is popular, well-documented, and has a large userbase. Mojo CSS is newer, lightweight, and requires no CSS coding. Tailwind is recommended for most projects, but Mojo CSS might be a good choice for lightweight projects.
- 22
- 23
- 24
- 25