Best of CSSJune 2024

  1. 1
    Article
    Avatar of devtoDEV·2y

    New CSS media queries syntax 💥

    The new CSS media query syntax simplifies defining responsive breakpoints, making code cleaner and more intuitive. It offers enhanced clarity, efficiency, and compatibility across modern browsers, streamlining the development process.

  2. 2
    Article
    Avatar of codemotionCodemotion·2y

    Creating a Fallout-Style UI Using Modern CSS

    Learn how to create a retro-futuristic user interface inspired by the Pip-Boy 3000 from the Fallout series using modern CSS techniques. The tutorial covers semantic HTML, responsiveness, typography and colors, responsive layout, visual effects and animations, and using generative AI for sci-fi content.

  3. 3
    Article
    Avatar of communityCommunity Picks·2y

    Get the Best Performance on Your Next.js App

    Learn how to optimize performance on your Next.js app with tips like loading only the necessary JavaScript and CSS, lazy loading dependencies, using the Next.js Image component for image optimization, preferring CSS over JavaScript, avoiding loaders at the beginning, utilizing font optimization, optimizing scripts, removing unused packages, checking bundle size, and using server components for improved rendering and caching.

  4. 4
    Article
    Avatar of communityCommunity Picks·2y

    What is this weird CSS Syntax?

    Learn about an interesting CSS syntax involving the adjacent sibling combinator (+) and the asterisk (*) to select non-immediate adjacent elements of the same class. This allows styles to be applied to specific siblings a few elements away when hovering over a targeted element.

  5. 5
    Video
    Avatar of kevinpowellKevin Powell·2y

    We can now transition to and from display: none

    Learn how to transition from display: none to display: block using CSS animations and transitions. Discover the difference between animations and transitions and how to animate a backdrop in CSS.

  6. 6
    Article
    Avatar of bramBram.us·2y

    CSS-only Custom Range Slider with Motion

    A CSS-only custom range slider with motion that updates the tooltip as you drag the thumb and incorporates scroll-driven animations.

  7. 7
    Article
    Avatar of css-irlCSS {IRL}·2y

    Modern CSS Layout is Awesome: Talking and Thinking About CSS Layout

    CSS layout talk discussing new CSS features and the importance of staying updated with them.

  8. 8
    Article
    Avatar of ishadeedAhmad Shadeed·2y

    CSS Cap Unit

    The author explores the problem of aligning a box between two words and keeping its height equal to uppercase letters. They propose three solutions and ultimately find the 'cap' unit to be the perfect solution.

  9. 9
    Article
    Avatar of devtoDEV·2y

    🚀 Emmet in VSCode ✨

    Emmet in Visual Studio Code (VSCode) is a powerful tool that speeds up HTML and CSS coding by expanding abbreviations into complete code structures. Key features include abbreviation expansion, code snippets, and fast navigation and editing. Examples showcase creating divs, lists, links, and basic HTML structures, demonstrating how Emmet can streamline the coding workflow.

  10. 10
    Article
    Avatar of lambdatestLambdaTest·2y

    How to Use CSS Layouts For Responsive Websites

    Learn about CSS layouts and how they are used to create structured and responsive web designs. Find out about different types of CSS layouts and understand how relative positioning works.

  11. 11
    Article
    Avatar of devtoDEV·2y

    CSS Variables (CSS Custom properties) for Beginners

    CSS variables, also known as CSS custom properties, allow for reusable values across a project, improving code readability and maintainability. This guide covers the basics of declaring and using CSS variables, including local and global declarations. It also explains how to dynamically update CSS values using JavaScript in response to user actions.

  12. 12
    Article
    Avatar of astro_sourceAstro·2y

    Zero-JavaScript View Transitions

    Astro introduces an update to the View Transitions API that allows for native, app-like page navigation without JavaScript. Chrome 126 and Microsoft Edge 126 support zero-JavaScript view transitions. To enable it, add the @view-transition at-rule to your website's CSS. The 'transition:persist' feature is not yet supported by native cross-document navigation.

  13. 13
    Video
    Avatar of awesome-codingAwesome·2y

    5 CSS Easy Features Everyone Should Know

    Learn about modern CSS features, including nesting rules, custom properties (CSS variables), container queries, styling parent elements based on children, and the grid layout.

  14. 14
    Article
    Avatar of hnHacker News·2y

    Grid Garden

    Grid Garden is a web-based game that helps users learn CSS grid by solving puzzles and applying grid properties.

  15. 15
    Article
    Avatar of communityCommunity Picks·2y

    Do you still need Framer Motion?

    The post discusses five new CSS features that might make Framer Motion unnecessary. It explores enter animations, independent transforms, springs, scroll-linked animations, and layout animations. While CSS has improved, the author still prefers the Framer Motion API for its simplicity and better user experience.

  16. 16
    Article
    Avatar of vigetViget·2y

    Fluid Breakout Layout with CSS Grid

    Learn how to use CSS Grid to create a fluid breakout layout that handles multiple width variations in components. No media queries required!

  17. 17
    Article
    Avatar of freecodecampfreeCodeCamp·2y

    Media Queries vs Container Queries – Which Should You Use and When?

    As the web evolves, new tools like media queries and container queries emerge, offering web developers various ways to make responsive designs. Media queries adapt styles based on the overall viewport size, suitable for different devices. Container queries, however, base their styles on the size of individual containers, promoting modularity and flexibility. While media queries are less effective for complex layouts, container queries support more adaptive component-based designs. Understanding each tool's strengths and considering project requirements will guide their best use in web design.

  18. 18
    Video
    Avatar of t3dotggTheo - t3․gg·2y

    This GitHub CSS Exploit Is WILD

    Exploits with CSS on GitHub were found, disclosed, and patched. The CSS injection allowed for the rendering of images and executing actions on the site.

  19. 19
    Article
    Avatar of communityCommunity Picks·2y

    A CSS-only game playable with keyboard! 🤯 (No, you are not dreaming)

    A CSS-only game that can be played using the keyboard. No hidden JavaScript and 100% CSS Magic. Record and share your best attempt!

  20. 20
    Article
    Avatar of hnHacker News·2y

    A Rant about Front-end Development

    A front-end developer expresses frustration with the complexity and misuse of modern web development technologies, emphasizing the importance of content over code. The post highlights common issues such as an over-reliance on JavaScript, misunderstandings about CSS, and the unnecessary complexity introduced by frameworks. The author advocates for simplicity, server-side rendering, and a focus on meaningful content.

  21. 21
    Article
    Avatar of frontendmastersFrontend Masters·2y

    :has() is “The God Selector” – Frontend Masters Boost

    The :has() selector in CSS, hailed as 'The God Selector' by Bruce Lawson, allows you to select any element based on the state of any other element without needing any structural relationship in the DOM. This makes it incredibly powerful for styling purposes.

  22. 22
    Article
    Avatar of csstipCSS Tip·2y

    Fancy hover effect with anchor positioning

    Experiment with anchor positioning to create fancy hover effects such as sliding and jumping for menu items.

  23. 23
    Article
    Avatar of communityCommunity Picks·2y

    Anchor Links and How to Make Them Awesome

    This post discusses anchor links and how to enhance them using CSS. It covers the basics of creating anchor links, enabling smooth scrolling, adding scroll margin, targeted page anchor styles, and more. It also explores nested scrolling and the difference between scroll margin and scroll padding. Overall, it provides a comprehensive guide to making anchor links awesome.

  24. 24
    Video
    Avatar of kevinpowellKevin Powell·2y

    "Smart" design patterns with container queries

    Container queries are a powerful CSS feature that allows styling based on the size of an element's container, rather than the viewport. This can lead to more flexible and meaningful breakpoints, particularly for component-based designs. The post explores practical examples, including making components adapt to the number of columns in a layout and how units like REM and EM work differently in container queries. The ability to create more intelligent design patterns without relying solely on viewport-based media queries is a key advantage.

  25. 25
    Article
    Avatar of communityCommunity Picks·2y

    Is CSS Tricks back?

    CSS Tricks, a website on the decline, may be revived after a year of dormancy. Chris Coyier, the original founder, expressed his desire to regain ownership and the current CEO of Digital Ocean is determined to bring CSS Tricks back. Former editor Geoff Graham may have returned to his old job. The future of CSS Tricks is uncertain.