Issue with Grand Stack Starter

Following the steps for a fresh install

yarn create grandstack-app myNewApp

neo4j desktop create database, install apoc.
upon running yarn run start the SPA loads up on port 3000 but the graphql server doesn't succeed

and it throws the error
GraphQLError [Object]: Argument "direction" has invalid value "OUT".

I ran into this same issue.

You might have the updated version of neo4j-graphql.js. Remove the "" from OUT and see if that works!

4 Likes

Thanks you. That fixed the issue.

I found this here after several hours of searching...
Ran into the same issue.

Removing "" for "IN" AND "OUT" fixed it.

Problem is that the docs still show examples with "IN" AND "OUT" etc.
I think this should be immediately fixed.

NOT WORKING

const typeDefs = `
type Movie {
    title: String
    year: Int
    imdbRating: Float
    genres: [Genre] @relation(name: "IN_GENRE", direction: "OUT")
}
type Genre {
    name: String
    movies: [Movie] @relation(name: "IN_GENRE", direction: "IN")
}
`;

WORKING

const typeDefs = `
type Movie {
    title: String
    year: Int
    imdbRating: Float
    genres: [Genre] @relation(name: "IN_GENRE", direction: OUT)
}
type Genre {
    name: String
    movies: [Movie] @relation(name: "IN_GENRE", direction: IN)
}
`;

neo4j-graphql/neo4j-graphql-js: A GraphQL to Cypher query execution layer for Neo4j and JavaScript GraphQL implementations. (github.com)

and btw. Why the change in the first place? and WTF?

Tnx, it works...aaakheysh.