mattwr18 4cd43b68a4 Refactor further search
- in the end, the error was due to not asking for the id of the author
back of the Post.. grrr.... why couldn't we get better error messages!!

- Co-authored-by: Moriz Wahl <moriz.wahl@gmx.de>
2019-12-13 15:56:18 +01:00

28 lines
433 B
JavaScript

import gql from 'graphql-tag'
export const findResourcesQuery = gql`
query($query: String!) {
findResources(query: $query, limit: 5) {
__typename
... on Post {
id
title
slug
commentsCount
shoutedCount
createdAt
author {
id
name
}
}
... on User {
id
name
slug
avatar
}
}
}
`