Advanced React ⚛️ Patterns

Patterns to enhance the flexibility and simplicity of

both your components APIs and implementations

Kent C. Dodds

Utah

wife, 4 kids, & a dog

PayPal, Inc.

Please Stand...

if you are able ❤️ ♿️

What this workshop is

  • Interactive and Hands-on
  • Advanced! (for experienced React developers)
  • Patterns that put a smile on your face when you are implementing components with them :D

What this talk is not

  • 100% practical examples
  • Covering everything you can do

What this workshop covers

  • Compound Components
  • Render Props
  • State Initializers
  • State Reducers
  • Control Props
  • Provider Pattern
  • Higher Order Components

Setup

If you can, do it now, even if you've already done it...

git clone https://github.com/kentcdodds/advanced-react-patterns-v2.git

cd advanced-react-patterns-v2

npm run setup --silent

Logistics

  • 🙋 Raise your hand to ask and answer questions. Feel free to make relevant comments as well!
  • 💬 🌎 Use the workshop chat room to ask and answer each others questions.
  • 📑 Fill out the elaboration and feedback forms for every exercise.
  • 📧 Ask questions on my AMA (kcd.im/ama).
  • 🐦 Follow me on twitter 😉 (twitter.com/kentcdodds).

Routine

  1. The why/exercise intro 👨‍💻
  2. Exercises 💪 (pair programming!?)
  3. Elaboration and Feedback Form 📑
  4. ? Bonus 👨‍🎓 👩‍🎓
  5. ? Help others 👩‍🔬 👨‍🔬
  6. ? Make pull requests 🙏

Let's
Get
STARTED!

Thank you!

Advanced React Patterns

By Kent C. Dodds

Advanced React Patterns

Making React components that can be used in multiple places is not hard. What is hard is when the use cases differ. Without the right patterns, you can find yourself with a highly complex component that requires a lot of configuration props and way too many if statements. With this course, you'll not only learn great patterns you can use, but also the strengths and weaknesses of each so you know which to reach for to provide your components the flexibility and power you need. I have contributed to and published some of the most successful React components in the React ecosystem. Through that experience, I've learned and taught patterns that enhance flexibility, usefulness, and simplicity.

  • 5,556