Search

Nalezeno "qr code": 1635

Using requestAnimationFrame with React Hooks


Animating with requestAnimationFrame should be easy, but if you haven’t read React’s documentation thoroughly then you will probably run into a few things that might cause you a headache. Here are three gotcha moments I learned the hard way. TLDR: Pass an empty array as a second parameter...

Lazy load embedded YouTube videos


This is a very clever idea via Arthur Corenzan. Rather than use the default YouTube embed, which adds a crapload of resources to a page whether the user plays the video or not, use the little tiny placeholder webpage that is just an image you can click that is linked to the YouTube embed. It still...

Mercurial Tips


While most of the world seems to be using git for version control, Mozilla continues to use Mercurial (hg) to manage the Firefox source code. As a git and GitHub lover, it took me a while to get used to Mercurial. I don’t consider myself a hg expert but I know enough to complete...

Staggered CSS Transitions


Let's say you wanted to move an element on :hover for a fun visual effect. @media (hover: hover) { .list--item { transition: 0.1s; transform: translateY(10px); } .list--item:hover, .list--item:focus { transform: translateY(0); } } Cool cool. But what if you had several list...

Contextual Utility Classes for Color with Custom Properties


In CSS, we have the ability to access currentColor which is tremendously useful. Sadly, we do not have access to anything like currentBackgroundColor, and the color-mod() function is still a ways away. With that said, I am sure I am not alone when I say I'd like to style some links based on...

The Differing Perspectives on CSS-in-JS


Some people outright hate the idea of CSS-in-JS. Just that name is offensive. Hard no. Styling doesn't belong in CSS, it belongs in CSS, a thing that already exists and that browsers are optimized to use. Separation of concerns. Anything else is a laughable misstep, a sign of not learning from...

All the New ES2019 Tips and Tricks


The ECMAScript standard has been updated yet again with the addition of new features in ES2019. Now officially available in node, Chrome, Firefox, and Safari you can also use Babel to compile these features to a different version of JavaScript if you need to support an older browser. Let’s look...

Are You Ready for Europe’s Unique Event Fin:CODE 2020?


DevOps | Scale | Velocity in the Financial Industry  Frankfurt, Germany | March 19 – 20, 2020: fin:CODE is Europe’s unique event mainly focused on addressing the challenges that banks, asset management firms and insurance companies are experiencing when adopting and scaling...

Design Principles for Developers: Processes and CSS Tips for Better Web Design


It is technically true that anyone can cook. But there’s a difference between actually knowing how to prepare a delicious meal and hoping for the best as you throw a few ingredients in a pot. Just like web development, you might know the ingredients—<span>, background-color, .heading-1—but...

How to Become a Blockchain Developer


Skilled blockchain developers are a scarce commodity, as precious as the bitcoins that reside on the distributed ledgers they maintain. Teach yourself one of the major blockchain programming languages and you’ll be set for life, though like anything worth having, this achievement won’t...

SSCCE


You know what a "reduced test case" is, right? We've talked about it here. I imagine the concept is useful in many walks of life, but in the world of front-end development, you can think of it like: A reduced test case is a demo/example page you create which reproduces the problem you are having...

Can you nest @media and @support queries?


Yes, you can, and it doesn't really matter in what order. A CSS preprocessor is not required. It works in regular CSS. This works: @supports(--a: b) { @media (min-width: 1px) { body { background: red; } } } And so does this, the reverse nesting of the above: @media (min-width:...

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