support for passing in array of elements