morpheus-graphql v0.4.0 Release Notes

Release Date: 2019-10-08 // over 4 years ago
  • ๐Ÿ”„ Changed

    ๐Ÿ‘Œ support of Default Value:

    • on query: Parsing Validating and resolving

    - on Document: only Parsing

    ๐Ÿšš lens is removed from Library, client field collision can be handled with GraphQL alias:

    { user { namefriend { friendName: name } } }
    

    ๐Ÿ›  Fixed:

    Data.Morpheus.Document.toGraphQLDocument generates only user defined types. #259

    Morpheus Client Namespaces Input Type Fields, they don't collide anymore:
    example:
    schema:

    input Person { name: String!}
    

    query:

    query GetUser (parent: Person!) { .... }
    

    wil generate:

    data GetUserArgs = GetUserArgs { getUserArgsParent: Person} deriving ...data Person = Person { personName: Person} deriving ...
    

    Morpheus Client Generated Output Object And Union Types don't collide:

    type Person { name: String!parent: Person!friend: Person!}
    

    And we select

    { user { namefriend { name } parent { name } bestFriend: friend { nameparent { name } } } }
    

    client will Generate:

    • UserPerson from {user
    • UserFriendPerson: from {user{freind
    • UserParentPerson: from {user{parent
    • UserBestFriendPerson: from {user{bestFrend

    - UserBestFriendParentPerson: from {user{bestFrend{parent

    GraphQL Client Defines enums and Input Types only once per query and they don't collide