Go to Previous Chapter
Go to Previous Chapter
SECTION 15
Using Webpack with Create React App
SECTION 16
Unit Testing
Fullstack React
CHAPTER 1
JSX and the Virtual DOM
SECTION 1.1
React Uses a Virtual DOM
SECTION 1.2
Why Not Modify the Actual DOM?
SECTION 1.3
What is a Virtual DOM?
SECTION 1.4
Virtual DOM Pieces
SECTION 1.5
ReactElement {#react_element}
SECTION 1.6
JSX
SECTION 1.7
References
CHAPTER 2
Relay Classic
SECTION 2.1
Introduction
SECTION 2.2
Relay is a Data Architecture
SECTION 2.3
Relay GraphQL Conventions
SECTION 2.4
Adding Relay to Our App
SECTION 2.5
BooksPage
SECTION 2.6
Changing Data With Mutations
SECTION 2.7
Building a Book's Page
SECTION 2.8
Mutations
SECTION 2.9
Conclusion
SECTION 2.10
Where to Go From Here
CHAPTER 3
GraphQL Server
SECTION 3.1
Writing a GraphQL Server
SECTION 3.2
Special setup for Windows users
SECTION 3.3
Connections
SECTION 3.4
Summary
CHAPTER 4
Using GraphQL
SECTION 4.1
Your First GraphQL Query
SECTION 4.2
GraphQL Benefits
SECTION 4.3
GraphQL vs. REST
SECTION 4.4
GraphQL vs. SQL
SECTION 4.5
Relay and GraphQL Frameworks
SECTION 4.6
Chapter Preview
SECTION 4.7
Consuming GraphQL
SECTION 4.8
Exploring With GraphiQL
SECTION 4.9
GraphQL Syntax 101
SECTION 4.10
Complex Types
SECTION 4.11
Exploring a Graph
SECTION 4.12
Graph Nodes
SECTION 4.13
Viewer
SECTION 4.14
Graph Connections and Edges
SECTION 4.15
Mutations
SECTION 4.16
Subscriptions
SECTION 4.17
GraphQL With JavaScript
SECTION 4.18
GraphQL With React
SECTION 4.19
Wrapping Up
CHAPTER 5
Changelog
CHAPTER 6
Appendix C: React Hooks
SECTION 6.1
Motivation behind Hooks
SECTION 6.2
How Hooks Map to Component Classes
SECTION 6.3
Using Hooks Requires react "next"
SECTION 6.4
useState() Hook Example
SECTION 6.5
useEffect() Hook Example
SECTION 6.6
useContext() Hook Example
SECTION 6.7
useRef() Hook Example
SECTION 6.8
Using Custom Hooks
SECTION 6.9
Writing Tests for React Hooks
SECTION 6.10
Community Reaction to Hooks
SECTION 6.11
References to the Different types of Hooks
SECTION 6.12
Future of Hooks
SECTION 6.13
More Resources
CHAPTER 7
Advanced Component Configuration with props, state, and children
SECTION 7.1
Intro
SECTION 7.2
How to use this chapter
SECTION 7.3
Components
SECTION 7.4
props are the parameters {#component_props}
SECTION 7.5
PropTypes {#component_proptypes}
SECTION 7.6
Default props with getDefaultProps() {#get_default_props}
SECTION 7.7
Context
SECTION 7.8
state {#component_state}
SECTION 7.9
Stateless Components
SECTION 7.10
Talking to Children Components with props.children {#component_props_children}
SECTION 7.11
Summary
SECTION 7.12
References
CHAPTER 8
How to Get the Most Out of This Book
SECTION 8.1
Overview
SECTION 8.2
Running Code Examples
SECTION 8.3
Code Blocks and Context
SECTION 8.4
Getting Help
SECTION 8.5
Emailing Us
SECTION 8.6
Get excited
CHAPTER 9
Intermediate Redux
SECTION 9.1
Using createStore() from the redux library
SECTION 9.2
Representing messages as objects in state
SECTION 9.3
Introducing threads
SECTION 9.4
Adding the ThreadTabs component
SECTION 9.5
Supporting threads in the reducer
SECTION 9.6
Adding the action OPEN_THREAD
SECTION 9.7
Breaking up the reducer function
SECTION 9.8
Adding messagesReducer()
SECTION 9.9
Defining the initial state in the reducers
SECTION 9.10
Using combineReducers() from redux
SECTION 9.11
Next up
CHAPTER 10
Your first React Web Application
SECTION 10.1
Building Product Hunt
SECTION 10.2
Setting up your development environment
SECTION 10.3
Special instruction for Windows users
SECTION 10.4
JavaScript ES6/ES7
SECTION 10.5
Getting started
SECTION 10.6
What's a component?
SECTION 10.7
Building Product
SECTION 10.8
Making Product data-driven
SECTION 10.9
React the vote (your app's first interaction)
SECTION 10.10
Updating state and immutability
SECTION 10.11
Refactoring with the Babel plugin transform-class-properties {#babel-preset-tcp}
SECTION 10.12
Congratulations!
CHAPTER 11
Intro to Flux and Redux
SECTION 11.1
Why Flux?
SECTION 11.2
Flux implementations
SECTION 11.3
Redux
SECTION 11.4
Building a counter
SECTION 11.5
Building the store
SECTION 11.6
The core of Redux
SECTION 11.7
The beginnings of a chat app
SECTION 11.8
Building the reducer()
SECTION 11.9
Subscribing to the store
SECTION 11.10
Connecting Redux to React
SECTION 11.11
Next up
CHAPTER 12
Routing
SECTION 12.1
What's in a URL?
SECTION 12.2
Building the components of react-router
SECTION 12.3
Dynamic routing with React Router
SECTION 12.4
Supporting authenticated routes
SECTION 12.5
Recap
CHAPTER 13
Components
SECTION 13.1
A time-logging app
SECTION 13.2
Getting started
SECTION 13.3
Breaking the app into components
SECTION 13.4
The steps for building React apps from scratch
SECTION 13.5
Step 2: Build a static version of the app
SECTION 13.6
Step 3: Determine what should be stateful
SECTION 13.7
Step 4: Determine in which component each piece of state should live
SECTION 13.8
Step 5: Hard-code initial states
SECTION 13.9
Step 6: Add inverse data flow
SECTION 13.10
Updating timers
SECTION 13.11
Deleting timers
SECTION 13.12
Adding timing functionality
SECTION 13.13
Add start and stop functionality
SECTION 13.14
Methodology review
CHAPTER 14
Appendix B: ES6
CHAPTER 15
Using Webpack with Create React App
SECTION 15.1
Exploring Create React App
SECTION 15.2
Webpack basics
SECTION 15.3
Making modifications to the sample app
SECTION 15.4
Creating a production build
SECTION 15.5
Ejecting
SECTION 15.6
Using Create React App with an API server
SECTION 15.7
Webpack at large
CHAPTER 16
Unit Testing
SECTION 16.1
Writing tests without a framework
SECTION 16.2
What is Jest?
SECTION 16.3
Using Jest
SECTION 16.4
Testing strategies for React applications
SECTION 16.5
Testing a basic React component with Enzyme
SECTION 16.6
Writing tests for the food lookup app
SECTION 16.7
Writing FoodSearch.test.js
SECTION 16.8
Further reading
CHAPTER 17
Appendix A: PropTypes {#appendix_prop_types}
SECTION 17.1
Validators
SECTION 17.2
string
SECTION 17.3
number
SECTION 17.4
boolean
SECTION 17.5
function
SECTION 17.6
object
SECTION 17.7
object shape
SECTION 17.8
multiple types
SECTION 17.9
instanceOf
SECTION 17.10
array
SECTION 17.11
array of type
SECTION 17.12
node
SECTION 17.13
element
SECTION 17.14
any type
SECTION 17.15
Optional & required props
SECTION 17.16
custom validator
CHAPTER 18
Forms
SECTION 18.1
Forms 101
SECTION 18.2
Text Input
SECTION 18.3
Remote Data
SECTION 18.4
Async Persistence
SECTION 18.5
Redux
SECTION 18.6
Form Modules
CHAPTER 19
Components & Servers
SECTION 19.1
Introduction
SECTION 19.2
server.js
SECTION 19.3
The Server API
SECTION 19.4
Playing with the API
SECTION 19.5
Loading state from the server
SECTION 19.6
client
SECTION 19.7
Sending starts and stops to the server
SECTION 19.8
Sending creates, updates, and deletes to the server
SECTION 19.9
Next up
CHAPTER 20
Using Presentational and Container Components with Redux
SECTION 20.1
Removing store from App
SECTION 20.2
Generating containers with react-redux
SECTION 20.3
Action creators
SECTION 20.4
Conclusion
CHAPTER 21
React Native
SECTION 21.1
Init
SECTION 21.2
Routing
SECTION 21.3
Play around with it
SECTION 21.4
<Navigator />
SECTION 21.5
Web components vs. Native components
SECTION 21.6
Styles
SECTION 21.7
HTTP requests
SECTION 21.8
What is a promise
SECTION 21.9
Single-use guarantee
SECTION 21.10
Creating a promise
SECTION 21.11
Debugging with React Native
SECTION 21.12
Where to go from here
Go to Next Chapter
Go to Next Chapter
SECTION 17
Appendix A: PropTypes {#appendix_prop_types}
Go Pro
Log In
Unit Testing
Table of Contents
Section 16.1
Writing tests without a framework
Section 16.2
What is Jest?
Section 16.3
Using Jest