The React snippet collection contains function components and reusable hooks for React 16.
React, Render
Take a deeper dive into React's rendering process and understand the basics behind the popular JavaScript framework.
React, Render
Take a deeper dive into React's rendering process and understand the role of the Context API and Redux in it.
Testing React components that update asynchronously with React Testing Library is a common scenario. Learn how to deal with common issues and speed up your testing.
React, Components
Renders a tag input field.
React, Logic
When working with state in your code, you often run into issues with maintaining complexity and readability. Oftentimes, these issues are easily fixable.
React, Render
Take a deeper dive into React's rendering process and understand how to make small yet powerful tweaks to optimize performance.
React, Components
Renders a checkbox list that uses a callback function to pass its selected value/values to the parent component.
React, Components
Renders a textarea component with a word limit.
React, Components
Renders a Modal component, controllable through events.
React, Components
Renders a tabbed menu and view component.
React, Hooks
Wrapping your mind around React hooks and how they interact with setInterval()
can be difficult. Here's a guide to get you started.
Testing Redux-connected components with React Testing Library is a very common scenario. Learn how to use this simple utility function to speed up your testing.
React, Testing
Testing stateful React components is by no means a difficult task, but did you know there is an elegant solution that doesn't involve testing state directly?
React, Components
Renders a tree view of a JSON object or array with collapsible content.
React, Components
Renders an accordion menu with multiple collapsible content elements.