You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
So my application I need to render a list of items, the list is user defined, and user can mix and match item types as much as they want. Basically its a list of activities that are sequenced by a content creator and show to a user.
However I already have the types and parsing logic for these different item defined in a common rendering library. I would like to write a scalar that parses these items, and returns a fully resolved type to the front end.
is this possible with Graphql? I know there was some discussion a while back about adding Scalar Unions... does any one if that was resolved? If not is there a way to make my usecase work?
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
Uh oh!
There was an error while loading. Please reload this page.
-
So my application I need to render a list of items, the list is user defined, and user can mix and match item types as much as they want. Basically its a list of activities that are sequenced by a content creator and show to a user.
Example
These are stored on back-end service that my GQL service interfaces with. The Backend service just stores this as Stringified JSON.
On my GQL service I am just using a simple scalar to parse that string for the use.
However I already have the types and parsing logic for these different item defined in a common rendering library. I would like to write a scalar that parses these items, and returns a fully resolved type to the front end.
is this possible with Graphql? I know there was some discussion a while back about adding Scalar Unions... does any one if that was resolved? If not is there a way to make my usecase work?
Beta Was this translation helpful? Give feedback.
All reactions