diff --git a/src/templates/post.js b/src/templates/post.js index ae0bc0c..6f5c914 100755 --- a/src/templates/post.js +++ b/src/templates/post.js @@ -1,6 +1,7 @@ import React from 'react' import PropTypes from 'prop-types' import { graphql } from 'gatsby' +import { Link } from 'gatsby' import Helmet from 'react-helmet' import { Layout } from '../components/common' @@ -40,6 +41,15 @@ const Post = ({ data, location }) => { className="content-body load-external-scripts" dangerouslySetInnerHTML={{ __html: post.html }} /> +
+

+ Written by { post.authors.map((author, key) => ([ + { author.name }, + { key == post.authors.length-1 ? '' : + key == post.authors.length-2 ? ' and ' : ', ' } + ]))} +

+