Returns the matched suffix for the string (if it exists). Great for matching string union types.
endsWithOneOf('cb', 'a', 'b'); // 'b'endsWithOneOf('cc', 'a', 'b'); // undefined Copy
endsWithOneOf('cb', 'a', 'b'); // 'b'endsWithOneOf('cc', 'a', 'b'); // undefined
Returns the matched suffix for the string (if it exists). Great for matching string union types.