diff --git a/components/SitePost/index.jsx b/components/SitePost/index.jsx index 01a693a..c92aec7 100644 --- a/components/SitePost/index.jsx +++ b/components/SitePost/index.jsx @@ -1,52 +1,51 @@ -import React from 'react' -import moment from 'moment' -import { RouteHandler, Link } from 'react-router' -import { prefixLink } from 'gatsby-helpers' -import access from 'safe-access' -import { config } from 'config' -import ReadNext from '../ReadNext' -import './style.css' -import '../../static/css/highlight.css' +import React from 'react'; +import moment from 'moment'; +import { Link } from 'react-router'; +import { prefixLink } from 'gatsby-helpers'; +import { config } from 'config'; +import ReadNext from '../ReadNext'; +import './style.css'; +import '../../static/css/highlight.css'; class SitePost extends React.Component { - render() { - const {route} = this.props - const post = route.page.data - const home = ( -
- All Articles - -
- ) + render() { + const { route } = this.props; + const post = route.page.data; + const home = ( +
+ All Articles +
+ ); - return ( -
- { home } -
-
-

{ post.title }

-
-
- Published { moment(post.date).format('D MMM YYYY') } -
-
-
- -
-

- { config.siteDescr } - -

{ config.siteAuthor } on Twitter
-

-
-
+ return ( +
+ {home} +
+
+

{post.title}

+
+
+ Published {moment(post.date).format('D MMM YYYY')}
- ); - } +
+
+ +
+

+ {config.siteDescr} + +
{config.siteAuthor} on Twitter +
+

+
+
+
+ ); + } } SitePost.propTypes = { - route: React.PropTypes.object.isRequired -} + route: React.PropTypes.object.isRequired, +}; -export default SitePost +export default SitePost;