I am using Mongodb and nodejs. I have stored array values in variable.below like this.
tag = ["58622e3bf39d570b21ece1b3", "58622e3bf39d570b21ece1a2", "58622e3bf39d570b21ece1r3"]
when i stored tag in mongodb database, I need to convert like this below.
tag = [ObjectId("58622e3bf39d570b21ece1b3"), ObjectId("58622e3bf39d570b21ece1a2"), ObjectId("58622e3bf39d570b21ece1r3")]
using nodejs, how to add objectId to array/list. without mongoose. is it possible?