Returns the key-value pair if this is a 'keyvalue' variant.
The walk element to extract from
Tuple of [key, value] if keyvalue, undefined otherwise
const element: WalkElement = { type: 'keyvalue', key: keyValue, value: valValue };const pair = asKeyValue(element); // Returns [keyValue, valValue] Copy
const element: WalkElement = { type: 'keyvalue', key: keyValue, value: valValue };const pair = asKeyValue(element); // Returns [keyValue, valValue]
Returns the key-value pair if this is a 'keyvalue' variant.