Skip to content

problem on sorting with graphql #3065

@pinaudnico

Description

@pinaudnico

I try something like this:
allImageSharp (sort: {fields:id}){
edges {
node {
sizes {
src
originalImg
originalName
}
}
}
}

it works on the graphiQL web window but when I put it in my gatsby it says
GraphQLError: Argument "sort" has invalid value {fields: "id"}.
In field "fields": Expected type "ImageSharpConnectionSortByFieldsEnum", found "id".

Any ideas ? Thanks.

Metadata

Metadata

Assignees

No one assigned

    Labels

    type: documentationAn issue or pull request for improving or updating Gatsby's documentationtype: question or discussionIssue discussing or asking a question about Gatsby

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions