#310 React — 5 things that might surprise you

sponsor

The Ultimate Guide to Building a UI Component Library—Establishing a Development Environment

Let’s walk through the steps you can take to set up a development environment that enables you to develop a component library. In this blog, you will also learn how to have a built npm package ready to distribute to other developers at your company. Check it out!

this week's favorite

React — 5 things that might surprise you

The React library is pretty straightforward and is relatively easy to get into, especially with the wide variety of materials that exist to help you learn it. But every tool has its share of tricks or issues that these tutorials usually don’t cover. You get to learn them when someone reviews your code, or worse — when you’re facing a problem and are desperate to find a solution. Hopefully, with this article, I might reveal some of these things about React, and maybe even surprise you!

A guide to behaviour testing in React with Enzyme and Jest

Writing proper behaviour tests in React with Enzyme and Jest is not a trivial task. I have spent three years on this topic and in this article, I will share my learnings and guidelines to how you can get more useful, reliable, and meaningful behaviour tests for your React code if you are only allowed to use Enzyme.

Demystifying styled-components

Somehow, using an obscure half-string-half-function syntax, the tool was able to take some arbitrary CSS and assign it to a React component, bypassing the CSS selectors we've always used.

React Futures - Server Components

If you are familiar with React, you know that it is a client-side library that provides developers with a set of abstractions on top of JavaScript that quickly and efficiently write the user interface to a web application. A client-side library means rendering the view in the DOM is done on the client’s browser using JavaScript. The server, in this case, is only responsible for delivering the bundles of your application containing HTML, CSS, and JavaScript and doesn’t perform any rendering.

A better React 18 startTransition demo

Further testing showed that every render takes less than 1ms. startTransition and time slicing didn't even have time to kick in.

newsletters

Would you like to become a sponsor and advertise in one of the issues? Check out our media kit and get in touch.