Solved

interfaces vs. types

  • 20 March 2023
  • 1 reply
  • 43 views

Userlevel 3
Badge

More of a design question: only interfaces are allowed after the implements keyword, so you have to know what types you plan to extend beforehand, but this is not always possible or reliable. Since interfaces also produce views, I am tempted to make everything an interface, but are there any downsides?

icon

Best answer by Anders Hafreager 21 March 2023, 09:44

View original

1 reply

Userlevel 3

Yeah, this is following the GraphQL spec. You can actually use interface everywhere and that should work fine! 

Reply