if item is not in array php code example
Example 1: typescript check if element in array
your_array.includes(the_element)
Example 2: in javascript check is is an array or not
Array.isArray(yourItem)
your_array.includes(the_element)
Array.isArray(yourItem)