Преглед на файлове

Listing 3: composing components: composing CommentBox of CommentList and CommentForm.

Frederic G. MARAND преди 9 години
родител
ревизия
257f06693e
променени са 1 файла, в които са добавени 3 реда и са изтрити 1 реда
  1. 3 1
      public/scripts/tutorial.js

+ 3 - 1
public/scripts/tutorial.js

@@ -22,7 +22,9 @@ let CommentBox = React.createClass({
   render: function () {
     return (
       <div className="commentBox">
-        Hello, world: I am a CommentBox.
+        <h1>Comments</h1>
+        <CommentList />
+        <CommentForm />
         </div>
     );
   }