Giter VIP home page Giter VIP logo

Comments (4)

victorgarciaesgi avatar victorgarciaesgi commented on May 30, 2024 1

Hi @yss14 and thanks! 😀
Union types is a missing feature I wanted to implement but i have no project that rely on it so it was not on my priority list.
I can work on it when i go back from vacation monday, it would help me a lot if you can provide me a introspection json schema of your graphql api to see how i can identify union types (or endpoint but i suppose it's not public).

Also how do you want it to be shaped in Typescript?

Something like type UnionType = Type1 | Type2?

from simple-graphql-to-typescript.

victorgarciaesgi avatar victorgarciaesgi commented on May 30, 2024 1

@yss14 Added on 0.7.7! Could you try it and tell me if it works well for you? :D

from simple-graphql-to-typescript.

yss14 avatar yss14 commented on May 30, 2024

Thanks for the fast response @victorgarciaesgi !
The endpoint is available here: https://api-beta.musicshare.rocks/graphql
type UnionType = Type1 | Type2 looks good to me, I think that's also the way other code generators handle it.
Thank you for adding this feature!

from simple-graphql-to-typescript.

yss14 avatar yss14 commented on May 30, 2024

@victorgarciaesgi Works like a charm! Thank you very much :)

from simple-graphql-to-typescript.

Related Issues (7)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.