Search

Nalezeno "Link": 1156

CSS fix for 100vh in mobile WebKit


A surprisingly common response when asking people about things they’d fix about anything in CSS, is to improve the handling of viewport units. One thing that comes up often is how they relate to scrollbars. For example, if an element is sized to 100vw and stretches edge-to-edge, that’s...

WTF is a Static API


Just like there is a movement to make more websites (and more of websites) from pre-rendered static files (Jamstack), so to might we consider moving content-based APIs to be static. Sean C Davis: A static API is simply a collection of flat JSON files that live on a content delivery...

Pseudo-elements in the Web Animations API


To use the Web Animations API (e.g. el.animate()) you need a reference to a DOM element to target. So, how do you use it on pseudo-elements, which don’t really offer a direct reference? Dan Wilson covers a (newish?) part of the API itself: const logo...

Why does writing matter in remote work?


Talk to anyone who has an active blog and I bet they’ll tell you it’s been valuable to them. Maybe it’s opened doors. Maybe it’s got them a job. Maybe it’s got them a conference invite. Maybe they just like the thrill of knowing people have read and responded to...

How I Put the Scroll Percentage in the Browser Title Bar


Some nice trickery from Knut Melvær. Ultimately the trick boils down to figuring out how far you’ve scrolled on the page and changing the title to show it, like: document.title = `${percent}% ${post.title}` Knut’s trick assumes React and installing an additional library. I’m sure...

min(), max(), and clamp() are CSS magic!


Nice video from Kevin Powell. Here are some notes, thoughts, and stuff I learned while watching it. Right when they came out, I was mostly obsessed with font-size usage, but they are just functions, so they can be used anywhere you’d use a number, like a length. Sometimes pretty basic usage...

Modern CSS Solutions for Old CSS Problems


This is a hell of a series by Stephanie Eckles. It’s a real pleasure watching CSS evolve and solve problems in clear and elegant ways. Just today I ran across this little jab at CSS in a StackOverflow answer from 2013. This particular jab was about CSS lacking a way to pause between...

Chromium lands Flexbox gap


I mentioned this the other day via Michelle Barker’s coverage, but here I’ll link to the official announcement. The main thing is that we’ll be getting gap with flexbox, which means: .flex-parent { display: flex; gap: 1rem; } .flex-child { flex: 1; } That’s excellent...

Exciting Things on the Horizon For CSS Layout


Michelle Barker notes that it’s been a heck of a week for us CSS layout nerds. Firefox has long had the best DevTools for CSS Grid, but Chrome is about to catch up and go one bit better by visualizing grid line numbers and names. Firefox supports gap for display: flex, which is great,...

Angular + Jamstack! (Free Webinar)


(This is a sponsored post.) It’s easy to think that working with Jamstack means working with some specific set of technologies. That’s how it’s traditionally been packaged for us. Think LAMP stack, where Linux, Apache, MySQL and PHP are explicit tools and languages. or MEAN...

Enable Gatsby Incremental Builds on Netlify


The concept of an “incremental build” is that, when using some kind of generator that builds all the files that make for a website, rather than rebuilding 100% of those files every single time, it only changes the files that need to be changed since the last build. Seems like...

The Hero Generator


Sarah: I’ve had to implement the same hero for several years now, so like a good lazy programmer, I figured I’d automate it. Direct Link to Article — Permalink… Read article “The Hero Generator” The post The Hero Generator appeared first on CSS-Tricks

Real-World Effectiveness of Brotli


Harry Roberts: The numbers so far show that the difference between no compression and Gzip are vast, whereas the difference between Gzip and Brotli are far more modest. This suggests that while the nothing to Gzip gains will be noticeable, the upgrade from Gzip to Brotli might perhaps...

Different Approaches to Responsive CSS Motion Path


As a follow-up to Jhey’s recent post on responsive motion paths, Michelle Barker notes that another approach could be to just transform: scale() the whole dang element. The trade-off there is that you’re scaling both the path and the element on the path at the same time; Jhey’s...

Innovating on Web Monetization: Coil and Firefox Reality


I still think Coil is cool. I have it installed on CSS-Tricks as a publisher and money trickles in. I have a paid account and I trickle out money to other sites that use it. I wrote about all that last year. This’ll explode to something huge if we actually get the Web Monetization API stuff....

My Visual Studio Code Setup: Extensions and Themes


Matthias Ott’s posted his VS Code setup. I find lists like this (I rounded up some recent updates of my own) irresistible, probably because, like y’all, I spend an awful lot of time in VS Code and wanna make sure I’m getting the most out of it. Things from the list that stood...

Puzzles and Mysteries


Bob Hoffman: Puzzles, [Malcom Gladwell] wrote, are problems for which there is not enough information. An example of a puzzle: Where is Jimmy Hoffa buried? If we had more information, we would know the answer. If someone told us “Jimmy Hoffa is buried in New Jersey,” we’d know a little more than...

Nahoru
Tento web používá k poskytování služeb a analýze návštěvnosti soubory cookie. Používáním tohoto webu s tímto souhlasíte. Další informace