Array syntax for typeDefs argument not supported
See original GitHub issueI’m working on migrating an apollo graphql server to graphql-yoga
, I’m strugling with modularizing schemas. like described HERE.
I know it’s possible to keep using new GraphQLServer
passing a GraphQLSchema
instead of passing typeDefs
and resolvers
.
I’m following same approach as above I’m getting this:
if (typeDefs.endsWith('graphql')) {
Is there a way to modularize typeDefs without instantiating GraphQLSchema
and passing it to GraphQLServer
?
Issue Analytics
- State:
- Created 6 years ago
- Comments:9 (9 by maintainers)
Top Results From Across the Web
Array syntax for typeDefs argument not supported #185 - GitHub
I'm working on migrating an apollo graphql server to graphql-yoga, I'm strugling with modularizing schemas. like described HERE.
Read more >array of function pointers with/out typedef and explicit ...
I wonder about the fact that is possible to omit the argument(s) for the array of function pointers. Again, if I write typedef2...
Read more >Passing Arrays as Function Arguments in C - Tutorialspoint
If you want to pass a single-dimension array as an argument in a function, you would have to declare a formal parameter in...
Read more >Array declaration - cppreference.com
An array type and its element type are always considered to be identically qualified, except that an array type is never considered to...
Read more >JSDoc Reference - TypeScript: Documentation
You can specify map-like and array-like objects using string and number index signatures, using either standard JSDoc syntax or TypeScript syntax.
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
I know that using
graphql-import
is better than using another modularize approach. But if you want to help people to joingraphql-yoga
things should be more intuitive. I think that acceptinggraphql-tools
’ way of modularizing schema will make yoga friendlierThe best way to modularize your schemas is by using
graphql-import
. You can split your schema into as many different files as you want that way, and import them into your final schema.Also, you can pass both a
string
and a filename totypeDefs
, so if you are usinggraphql-import
, you can just pass in the filename to that schema file.