%dw 2.0
output application/json
---
[ "Mariano" endsWith "no", "Mariano" endsWith "to" ]
DataWeave
endsWith
endsWith(String, String): Boolean
Returns true
if a string ends with a provided substring, false
if not.
Parameters
Name | Description |
---|---|
|
The input string (a |
|
The suffix string to find at the end of the input string. |
Example
This example finds "no" (but not "to") at the end of "Mariano".
Source
Output
[ true, false ]
JSON