Answer the question
In order to leave comments, you need to log in
Render not an array but a ReactJS object?
Having heard a lot of fables about how good React is, I decided to try it. I ran into a problem
in the tutorial there is an example
// tutorial10.js
var CommentList = React.createClass({
render: function() {
var commentNodes = this.props.data.map(function (comment) {
return (
<Comment author={comment.author}>
{comment.text}
</Comment>
);
});
return (
<div className="commentList">
{commentNodes}
</div>
);
}
});
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question