Many CSS properties are shorthands for a set of other properties, for example the margin property is a shorthand for setting margin-top , margin-right , margin-bottom , and margin-left all at once. Because the margin property decomposes into those four separate properties, it translates well to a utility class system like Tailwind CSS, where we can create separate utility classes for each…
This was originally posted as a thread on Twitter , but I thought I'd republish it here to give it a proper home. So about a month or so ago, Tailwind cracked 10 million total installs, which given its humble beginnings, completely blows my mind. We're also about to cross $2 million in revenue from Tailwind UI , our first commercial Tailwind CSS product which was released about 5 months ago — a…
When single-page applications were really getting popular in the early Backbone/Ember/Angular days, one of the biggest selling points was that you could navigate around your site without re-rendering the entire document from scratch every time the URL changed. This meant you could do things like preserve the scroll position in part of the UI that didn't change (like a sidebar for example) without…
Late into Halloween night in 2017, we released the very first version of Tailwind CSS — a utility-first CSS framework for rapidly developing custom user interfaces. Since then: We've published 30 releases 77 people have contributed to the codebase The GitHub repository has been starred over 8,000 times Over 1,100 people joined the Tailwind CSS Slack community Over 10,000 people started following…
Something I've struggled with in the past is looking back on the previous year and wondering "what did I even get done?" and "did I really make the best of my time?" It's easy to stress about the things you didn't get done, and even easier to forget about the things you did, so this year I've decided to start a tradition of capturing it all in one place to avoid being so dismissive of my own…
Scoped slots are one of Vue's most powerful features, but it can be a bit tricky to understand how they work when first learning about them. In this screencast (taken from my Advanced Vue Component Design course) , I walk through how thinking of scoped slots as function props can make it a lot easier to wrap your head around them. Learning More If you enjoyed this screencast, check out Advanced…
Have you ever pulled in a third-party UI component only to discover that because of one small tweak you need to make, you have to throw out the whole package? Custom controls like dropdowns, date pickers, or autocomplete fields can be very complex to build with a lot of unexpected edge cases to deal with. There are a lot of libraries out there that do a great job handling this complexity, but they…
Update : It looks like the bug in Safari has been fixed in Safari 15 , so I wholeheartedly recommend using em for media queries now. Keeping the post up for historical reasons, but the conclusion is no longer valid. In March 2016, Zell Liew published a really great in-depth post titled "PX, EM, or REM Media Queries?" , where he shared detailed tests he had performed to figure out which unit was…
Over the last several years, the way I write CSS has transitioned from a very "semantic" approach to something much more like what is often called "functional CSS." Writing CSS this way can evoke a pretty visceral reaction from a lot of developers, so I'd like to explain how I got to this point and share some of the lessons and insights I've picked up along the way. Phase 1: "Semantic" CSS One of…
Last May I released my first digital product, a book called "Refactoring to Collections" that teaches PHP developers how to use functional programming ideas to write cleaner code. Within the first three days it generated $61,392 in revenue and gave me the confidence to quit my day job and work on my own ideas full-time. Here's the whole story, from idea to launch. Finding an Idea Feb 16, 2016 –…