Code Snippets DataWeave

Short texts DataWeave 🧑‍💻 Code snippets DataWeave ✍️ Reading lists DataWeave 👀

unionType.dwl

%dw 2.0 output application/json fun myFunc(a: Array | String) = a match { case is Array -> $ joinBy ‘,’ else -> a } — myFunc([“Test”, “Test2”])