Setting up the application
"Shawn, we were using JSBin up to this point. But now we will create the app locally. We will use the following directory structure for our code:"
$ tree -L 1 . ├── LICENSE ├── README.md ├── index.html ├── node_modules ├── package.json ├── server.js ├── src └── webpack.config.js 2 directories, 6 files
The
src
directory will contain all of the React componentsThe
webpack.config.js
andserver.js
file will be used for setting up local development server using webpack.The
package.json
file will be used to contain information about all of the npm packages used by usThe
index.html
file will be the starting point of the app
"Let's see our index.html
file."
// index.html <html> <head> <title>Forms in React</title> <link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.5/css/bootstrap.min.css" /> </head> <body> <div id='root' class="container"> </div> </body> <script...