Why we’ll all use React Hooks

Sponsored · Ship Features Fearlessly Turn features on and off without deploys. Used by thousands of Ruby developers. →

Why we’ll all use React Hooks

This is the deck of my talk at FrontEnd Con 2018 (https://frontend-con.io/) in Warsaw, Poland on December 4th, 2018.

Hooks are a new feature proposal that lets you use state and other React features without writing a class. In this talk attendees could learn exactly what they are and how can they make React projects better.

Marcin Hagmajer

December 04, 2018

Annual Pro sale · Save $30

Have presentations of your own?

Share with private links, password protection, and more control over your work.

Transcript

29 slides
  1. Impure requirements • component state • data fetching • animations

    • notifications • subscriptions • more…
  2. “In the longer term, we expect Hooks to be the

    primary way people write React components.”
  3. Rules of hooks • useYourHook naming • Only Call Hooks

    at the Top Level • Only Call Hooks from React Functions
  4. Additional hooks • useReducer • useCallback • useMemo • useRef

    • useImperativeMethods • useLayoutEffects
  5. 100% backward compatible “At Facebook, we have tens of thousands

    of components written as classes, and we have absolutely no plans to rewrite them.”

Other Decks in Programming