Typegatewayv0.11.0
See also:InteractionGateContext, EventGateContext
type GateContext = InteractionGateContext | EventGateContext;// a gate that takes either context narrows on ctx.kind
const Either = defineGate('either', (ctx: GateContext) => {
if (ctx.kind === 'interaction') void ctx.interaction;
else void ctx.payload;
});