garph
garph copied to clipboard
Helper Methods: `or`
or
helper would help create a Union with the current type and the type specified in or
The use-case for the feature include error handling
Example:
const error = g.type('Error', {
message: g.string()
})
g.type('Test', {
test: g.string()
})
.or(error)