Kaynağa Gözat

Listing 6: Adding Markdown.

Frederic G. MARAND 8 yıl önce
ebeveyn
işleme
2d0fbfe1bf
1 değiştirilmiş dosya ile 1 ekleme ve 1 silme
  1. 1 1
      public/scripts/tutorial.js

+ 1 - 1
public/scripts/tutorial.js

@@ -5,7 +5,7 @@ let Comment = React.createClass({
         <h2 className="commentAuthor">
           {this.props.author}
         </h2>
-        {this.props.children}
+        {marked(this.props.children.toString())}
       </div>
     );
   }