Add blogpost page and cell

This commit is contained in:
Kurt Hutten
2020-10-10 12:18:23 +11:00
parent 029d6f4efc
commit 1a8bea1b85
9 changed files with 108 additions and 1 deletions

View File

@@ -0,0 +1,20 @@
export const QUERY = gql`
query BlogPostQuery($id: Int!) {
post(id: $id) {
id
title
body
createdAt
}
}
`
export const Loading = () => <div>Loading...</div>
export const Empty = () => <div>Empty</div>
export const Failure = ({ error }) => <div>Error: {error.message}</div>
export const Success = ({ post }) => {
return JSON.stringify(post)
}