mirror of
https://github.com/twisterarmy/twister-react.git
synced 2025-01-11 23:47:55 +00:00
25 lines
612 B
JavaScript
25 lines
612 B
JavaScript
|
|
var ReactBootstrap = require('react-bootstrap')
|
|
, NavItem = ReactBootstrap.NavItem
|
|
, Nav = ReactBootstrap.Nav
|
|
, ListGroup = ReactBootstrap.ListGroup
|
|
, Panel = ReactBootstrap.Panel
|
|
|
|
var React = require('react');
|
|
|
|
var Post = require("./Post.js");
|
|
|
|
module.exports = Postboard = React.createClass({displayName: "Postboard",
|
|
render: function() {
|
|
var posts = this.props.data.map(function(post, index) {
|
|
return (
|
|
React.createElement(Post, {post: post, key: post.postid})
|
|
);
|
|
});
|
|
return (
|
|
React.createElement(ListGroup, {fill: true},
|
|
posts
|
|
)
|
|
);
|
|
}
|
|
});
|