Jump to ratings and reviews
Rate this book

React Cookbook: Recipes for Mastering the React Framework

Rate this book
React helps you create and work on an app in just a few minutes, but learning how to put all the pieces together is hard. How do you validate a form? Or implement a complex multistep user action without writing messy code? How do you test your code? Make it reusable? Wire it to a backend? Keep it easy to understand? The React Cookbook delivers answers fast.

Many books teach you how to get started, understand the framework, or use a component library with React, but very few provide examples to help you solve particular problems. This easy-to-use cookbook includes the example code developers need to unravel the most common problems when using React, categorized by topic area and problem.

You'll learn how to:


Create a single-page application in React using a rich UI
Structure code that can be worked on by large teams
Integrate with backend services such as REST and GraphQL
Use offline caching with technologies such as Redux or MobX
Secure applications with technologies such as OAuth
Deal with bugs and avoid common functional and performance problems

510 pages, Paperback

Published September 14, 2021

5 people are currently reading
68 people want to read

About the author

David Griffiths

3 books1 follower
David Griffiths began programming at age 12, when he saw a documentary on the work of Seymour Papert. At age 15, he wrote an implementation of Papert's computer language LOGO. After studying Pure Mathematics at University, he began writing code for computers and magazine articles for humans. He's worked as an agile coach, a developer, and a garage attendant, but not in that order. He can write code in over 10 languages and prose in just one, and when not writing, coding, or coaching, he spends much of his spare time travelling with his lovely wife and co-author Dawn.

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
6 (33%)
4 stars
7 (38%)
3 stars
4 (22%)
2 stars
1 (5%)
1 star
0 (0%)
Displaying 1 - 3 of 3 reviews
2 reviews
December 27, 2021
An amazing book. Each section begins with problem, solution and discussion. In my opinion, this is an impressive technique to teach learners as this is something that engineers can have in day to day’s life.
Profile Image for Paul Grenyer.
67 reviews2 followers
September 4, 2022
This is a book of about 100 recipes across 11 sections. The sections range from the basics, such as creating React apps, routing and managing state to the more involved topics such as security, accessibility and performance.

I was especially pleased to see that the section on creating apps looked at create-react-app, nextjs and a number of other getting started tools and libraries, rather than just sticking with create-react-app.

I instantly liked the way each recipe laid out the problem it was solving, the solution and then had a discussion on different aspects of the solution. It immediately felt a bit like a patterns book. For example, after describing how to use create-react-app, the discussion section explains in more depth what it really is, how it works, how to use it to maintain your app and how to get rid of it.

As with a lot of React developers, the vast majority of the work I do is maintaining existing applications, rather than creating new ones from scratch. I frequently forget about how to setup things like routing scratch and would usually reach for Google. However, with a book like this I can see myself reaching for the easy to find recipes again and again.
Profile Image for Brant Gurganus.
7 reviews2 followers
June 5, 2022
This book lacked in recipes covering only two use cases. One of those use cases deviated from React quite a bit. The Router recipes were most useful but there were few and basically nothing else.
Displaying 1 - 3 of 3 reviews

Can't find what you're looking for?

Get help and learn more about the design.