Adds minor additions clarifying questions I had reading intro tutorial (#7595)
Robert Kielty committed
Aug 29, 2016 at 23:34 UTC
ee199381def77ed55551dfeca2d6604c1967b516
1 file changed
+2
-2
docs/docs/tutorial.md
+2
-2
@@ -181,7 +181,7 @@ Notice how we're mixing HTML tags and components we've built. HTML components ar
181
182
### Using props
183
184
-Let's create the `Comment` component, which will depend on data passed in from its parent. Data passed in from a parent component is available as a 'property' on the child component. These 'properties' are accessed through `this.props`. Using props, we will be able to read the data passed to the `Comment` from the `CommentList`, and render some markup:
184
+Let's create the `Comment` component, which will depend on data passed in from its parent, `CommentList`. Data passed in from a parent component is available as a 'property' on the child component. These 'properties' are accessed through `this.props`. Using props, we will be able to read the data passed to the `Comment` from the `CommentList`, and render some markup:
185
186
```javascript
187
// tutorial4.js
@@ -219,7 +219,7 @@ var CommentList = React.createClass({
219
});
220
```
221
222
-Note that we have passed some data from the parent `CommentList` component to the child `Comment` components. For example, we passed *Pete Hunt* (via an attribute) and *This is one comment* (via an XML-like child node) to the first `Comment`. As noted above, the `Comment` component will access these 'properties' through `this.props.author`, and `this.props.children`.
222
+Note that we have passed some data from the parent `CommentList` component to the child `Comment` components. For example, we passed *Pete Hunt* (via the `author` attribute) and *This is one comment* (via an XML-like child node) to the first `Comment`. As noted above, the `Comment` component will access these 'properties' through `this.props.author`, and `this.props.children`.
223
224
### Adding Markdown
225