joarwilk / gql2flow

Convert a GraphQL Schema to a flow definition
97 stars 24 forks source link

bug on GraphQLEnumType #15

Closed sibelius closed 7 years ago

sibelius commented 7 years ago

I have this GraphQLEnumType

export default new GraphQLEnumType({
  name: 'BirthdayFilter',
  values: {
    day: {
      value: 'day',
      description: 'people doing birthday today',
    },
    week: {
      value: 'week',
      description: 'people doing birthday in this week',
    },
    month: {
      value: 'month',
      description: 'people doing birthday in this month',
    },
  },
});

and it is generating this:

null
export type BirthdayFilter = "day" | "week" | "month";