Have you ever replaced fifty lines of JavaScript with a few lines of CSS, merged the PR, and felt like you just did the codebase a favor? You replace ResizeObserver with a container query, the diff is mostly red, and everyone approves it before lunch.
This was what it looked like before you made the change:
The selector matches more than we meant. The :has(img) rule matches any descendant image, so the comment’s avatar counted as a hero image. And the p element selector matches any descendant paragraph. As a result, the comment’s text was caught in the selection.
继续阅读全文
为了尊重作者,这里只展示开头几段。你可以去原文阅读,或者在 HorizonReader 里读:划线做笔记、让 AI 帮忙。
This article is a sponsored by TestMu AI Pass the string "10-03-2024" to new Date(), and the answer is browser-dependent. Chrome, Edge, and Firefox all return 3rd October 2024 with no warning. Safari returns Invalid Date. A user in Berlin w
As the year draws to a close, many of us are busy meeting deadlines, wrapping up projects, or getting ready for the holiday season. So why not take a moment amid the end-of-year hustle to set the mood for December? Our new collection of des
AI is changing how we design and build, and it isn’t slowing down. On December 1, 2026, SmashingConf is hosting the AI 2027 Conference, a live online half day event to take stock of where AI stands today, what we can expect in 2027, and whe
This article is a sponsored by Level Access Lately, I’ve been thinking and writing a lot about what AI is doing to product development, and what that means for accessibility. The thing that has my wheels turning is a finding from Level Acce
A product team at a large health insurer wants to add AI that writes the full written determination for benefits appeals specialists. The technology works as specified. However, the specialists stop using it, and the ones who keep using it