So I just tried to custom _id in mongoose schema like this :
const userSchema = new mongoose.Schema({
_id: {
type: String,
required: true,
unique: true
},
...
...
})
and get this message : mongoose: Cannot specify a custom index on _id for model name "SchemaName", MongoDB does not allow overwriting the default _id index.
The thing is, everything's fine. I can insert the data and select it like normal. Should I do something about that message?