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
I can convert the date to a date object by typing "new Date(response)". Response is the date string returned by the graphql query.
It would be great if we could add some kind of conversion strategy.
When doing that, we would get in case of a DateTime a real date object instead of an any object or a string.
At the moment I convert all the dates manually, would be cool to automate that.
Generally speaking: It would be cool to add a conversion strategy: What should be done with which scalar.
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
-
Hi there,
I realised, that even though when adding a new Scalar like DateTime, Date or Time (https://github.com/graphql-java/graphql-java-extended-scalars) the return type is still treated as an any type or string.
I can convert the date to a date object by typing "new Date(response)". Response is the date string returned by the graphql query.
It would be great if we could add some kind of conversion strategy.
When doing that, we would get in case of a DateTime a real date object instead of an any object or a string.
At the moment I convert all the dates manually, would be cool to automate that.
Generally speaking: It would be cool to add a conversion strategy: What should be done with which scalar.
Beta Was this translation helpful? Give feedback.
All reactions