Guest User

Untitled

a guest
Nov 14th, 2018
91
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.52 KB | None | 0 0
  1. import React from 'react';
  2.  
  3. class AddComments extends React.Component {
  4.  
  5.  
  6.  
  7. render(){
  8.  
  9. const timeGiven = this.props.commentData.timestamp;
  10. const timeDisplay = new Date(timeGiven);
  11. return(
  12. <>
  13. <span>
  14. <p className="comment-one">{this.props.name}</p>
  15. <p className="display-time">{timeDisplay}</p>
  16. </span>
  17. <p className="member-comment">{this.props.commentData.comment}</p>
  18. </>
  19. )
  20. }
  21. }
  22. export default AddComments;
Add Comment
Please, Sign In to add comment