Pure React: Learn vanilla React, without all the libraries. A hands-on, learn-by-doing intro to React for beginners, 4th Edition

Pure React: Learn vanilla React, without all the libraries. A hands-on, learn-by-doing intro to React for beginners, 4th Edition

English | 2019 | ISBN: 978-0553378443 | 272 Pages | PDF, EPUB | 17 MB

You’ll get hands-on practice by building a series of small components and micro apps — no big monolithic app here. The bite-size apps will have you reviewing concepts until they’re second nature.
What does the book cover?

  • An introduction to React 16.9 (the latest one, with Hooks)
  • Easy project setup with Create React App (you’ll be running code within minutes)
  • Debugging strategies for when things go wrong
  • Master JSX syntax, including “if”s, loops, and dynamic child components
  • Use props to make reusable components and communicate between them
  • How PropTypes can save you debugging time and help “future you” remember how to use the components you wrote
  • Use the “children” prop to render dynamic content
  • How to write React in modern ES6 Javascript, with just-in-time notes about ES6 syntax
  • How input controls work in React
  • Where and how to properly use state in your app
  • Learn the lifecycle of a component (and how to achieve the same results with the useEffect hook)
  • Learn to use the React Context API to pass data deeply through your app without prop drilling
  • Build stateful function components with React Hooks!
  • How to use each hook individually, and in combination
  • useState for simple state
  • useEffect for side effects (and you’ll learn what a “side effect” is)
  • useReducer for more complex state
  • useContext to easily pull data out of Context
  • useRef for inputs and more

The book has more than 17 step-by-step examples of React concepts, as well as 42 exercises to reinforce your knowledge.
You’ll start off with some simple components (tweets, dialog boxes, emails) and grow into more complex mini-apps. By the end you’ll have the skills to build that Slack clone you saw above, plus simplified versions of Trello, Hacker News, Pinterest, and Reddit.