var React = require('react') var Link = require('react-router').Link var UserID = require('userID.jsx') var GetIPFS = require('getipfs.jsx') var Post = require('post.jsx') module.exports = function (boardsAPI) { return React.createClass({ getInitialState: function () { return { } }, componentDidMount: function () { boardsAPI.use(boards => { this.setState({ api: boards }) }) }, getContext: function () { if (this.props.params.userid) { if (this.props.params.boardname) { return
Posted by in #{this.props.params.boardname}
} else { return
Posted by
} } else return
You are viewing a single post
}, render: function () { if (this.state.api) { return
{this.getContext()}
} else { return } } }) }