docbrown/app/javascript/chat/article.jsx
2020-03-06 20:03:49 +01:00

15 lines
354 B
JavaScript

import { h } from 'preact';
import PropTypes from 'prop-types';
const Article = ({ resource: article }) => (
<div className="activechatchannel__activeArticle">
<iframe src={article.path} title={article.title} />
</div>
);
Article.propTypes = {
resource: PropTypes.shape({
id: PropTypes.string,
}).isRequired,
};
export default Article;