set value as string or array of string mongo schema code example
Example: js array of strings mongoose
var personSchema = new mongoose.Schema({
tags: [{
type: String
}]
var personSchema = new mongoose.Schema({
tags: [{
type: String
}]