Is your feature request related to a problem? Please describe.
In order to write robust applications, it is important that application code handles unknown future values for enums.
Describe the solution you'd like
Making futureProofEnums the default would force consumers to handle unknown cases, making them more robust to schema evolutions.
The current value is named %future enum value but I would recommend __UNKNOWN instead which feels a little bit more inline with the usual GraphQL conventions.
Edit: never mind, __UNKNOWN is not what we want. but maybe %do not use this value, add a default case instead?
Relay has a linter rule to detect that all switches must also have a default: case
Is your feature request related to a problem? Please describe.
In order to write robust applications, it is important that application code handles unknown future values for enums.
Describe the solution you'd like
Making
futureProofEnumsthe default would force consumers to handle unknown cases, making them more robust to schema evolutions.The current value is named%future enum valuebut I would recommend__UNKNOWNinstead which feels a little bit more inline with the usual GraphQL conventions.Edit: never mind,
__UNKNOWNis not what we want. but maybe%do not use this value, add a default case instead?Relay has a linter rule to detect that all switches must also have a
default:case