I have cloud fire store object like this
"TestCollection" : ["Test1","Test"]
Now I want to update this array with FieldValue.arrayUnion because if element is same then i don't want to do anything but if it is not then I would like to add element
docRef.updateData({"TestCollection":FieldValue.arrayUnion(["test"])})
but this statement gives the error like object can not have nested array
Can anyone please help or provide same kind of example to have look for syntax ?