rommguy / react-reuse-patterns

Code for meetup on code reuse patterns in React apps

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

React reuse patters

This repository contains examples used for Wix Engineering meetup
Link to meetup
Link to slides
Video in Youtube

The app was created using create-react-app
React components used in the examples:

The directories are divided according to the presentation phases, each contains a MainView component.
To render the relevant part, switch the import of MainView in App.js
The parts are:

  • No reuse
  • Simple composition
  • Repackaging with composition
  • Repackaging with HOC
  • HOC communication with inner component (withState example)
  • Render callback - Dynamic communication with inner component (withState example)

About

Code for meetup on code reuse patterns in React apps


Languages

Language:JavaScript 92.5%Language:HTML 4.9%Language:CSS 2.6%