Jump to ratings and reviews
Rate this book

React Hooks in Action: With Suspense and Concurrent Mode

Rate this book
React Hooks in Action teaches you to write fast and reusable React components using Hooks.

Summary
Build stylish, slick, and speedy-to-load user interfaces in React without writing custom classes. React Hooks are a new category of functions that help you to manage state, lifecycle, and side effects within functional components. React Hooks in Action teaches you to use pre-built hooks like useState, useReducer and useEffect to build your own hooks. Your code will be more reusable, require less boilerplate, and you’ll instantly be a more effective React developer.

About the technology
Get started with React Hooks and you’ll soon have code that’s better organized and easier to maintain. React Hooks are targeted JavaScript functions that let you reuse and share functionality across components. Use them to split components into smaller functions, manage state and side effects, and access React features without classes—all without having to rearrange your component hierarchy.

About the book
React Hooks in Action teaches you to write fast and reusable React components using Hooks. You’ll start by learning to create component code with Hooks. Next, you’ll implement a resource booking application that demonstrates managing local state, application state, and side effects like fetching data. Code samples and illustrations make learning Hooks easy.

What's inside

Build function components that access React features
Manage local, shared, and application state
Explore built-in, custom, and third-party hooks
Load, update, and cache data with React Query
Improve page and data loading with code-splitting and React Suspense

About the reader
For beginning to intermediate React developers.

About the author
John Larsen has been a teacher and web developer for over 20 years, creating apps for education and helping students learn to code. He is the author of Get Programming with JavaScript.

Table of Contents

PART 1

1 React is evolving

2 Managing component state with useState hook

3 Managing component state with useReducer hook

4 Working with side effects

5 Managing component state with useRef hook

6 Managing application state

7 Managing performance with useMemo

8 Managing state with the Context API

9 Creating your own hooks

10 Using third party hooks

PART 2

11 Code splitting with Suspense

12 Integrating data-fetching with Suspense

13 Experimenting with useTransition, useDeferredValue and SuspenseList

376 pages, Paperback

Published April 13, 2021

12 people are currently reading
68 people want to read

About the author

John Larsen

27 books1 follower

Ratings & Reviews

What do you think?
Rate this book

Friends & Following

Create a free account to discover what your friends think of this book!

Community Reviews

5 stars
10 (23%)
4 stars
17 (39%)
3 stars
14 (32%)
2 stars
2 (4%)
1 star
0 (0%)
Displaying 1 - 6 of 6 reviews
Profile Image for Weekend Critic.
134 reviews3 followers
April 10, 2021
Not a bad book, however for the most part it is just react docs littered with a lot of code examples from the same tutorial app that spans the whole book. In my opinion such approach only distracts from learning and understanding the concepts and the theory behind them.

Book claims to be written for advanced level, but stops and explains everything a lot. Which is again not a bad thing, but why claim it is written for experienced engineers?

Overall I do not regret buying and reading this book but wouldn't recommend it either. React React documentation instead. And then if you still have some topics you didn't understand buy and read this book, and code on your own.
Profile Image for Dalton Sweeney.
26 reviews2 followers
February 22, 2022
Good book for learning react fundamentals. I liked the tutorial format where you slowly build an app throughout the entire book. It's a more effective learning strategy than independent code snippets (at least for me). I didn't read the last few chapters that cover Suspense and concurrent mode, which are experimental opt-in features. If your goal is to understand hooks and write production ready code then the final chapters are unnecessary.
Profile Image for Truong Binh.
66 reviews8 followers
Read
November 18, 2021
Clear and concise with detailed explanation on how React hooks work.
Profile Image for Morten .
82 reviews7 followers
May 9, 2022
A well written book on learning React and to master the use of React Hooks. A comprehensive intro how to build a React App with all the bells and whistles that it entails.
Displaying 1 - 6 of 6 reviews

Can't find what you're looking for?

Get help and learn more about the design.