Returns whether the given string ends with the suffix
Optional
the source string to check
the target string to compare
whether the given string ends with the suffix
David Hsing
endsWith('foobar', 'bar'); // trueendsWith('hello', 'bar'); // false Copy
endsWith('foobar', 'bar'); // trueendsWith('hello', 'bar'); // false
Returns whether the given string ends with the suffix