Skip to content

pohutukawa-2017/react-minimal

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

React minimal

As part of an introduction to React, this repo attempts to show React in a most basic form.

  • Many components can be simple functions.
  • Data to render in the component is passed in as props.
  • Assemble other components by importing them and calling them.

Setup

Clone this repo, and from the repo's folder

npm install
npm start

Next steps

  • Add new mount points and render components into them.
  • Add new components and use them inside existing components.
  • Render complex data structures (objects in objects) as props.
  • Check out the npm start script and the webpack.config.js file.
  • Conditionally show child components using a ternary operator.
  • Create child components from an array of data using .map().

Wat?

  • Why a simple Node server and not webpack-dev-server? Students seeing this repo for the first time are proficient with Node/Express. We've chosen to not throw out the concept of client/server even though we admittedly don't need a server here. We introduce webpack-dev-server later. Today we just want to focus on React concepts.

About

A super simple React starter

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • JavaScript 89.0%
  • HTML 11.0%