mongoose icon indicating copy to clipboard operation
mongoose copied to clipboard

SchemaType "Set"

Open alanpurple opened this issue 2 years ago • 0 comments

Prerequisites

  • [X] I have written a descriptive issue title
  • [X] I have searched existing issues to ensure the feature has not already been requested

🚀 Feature Proposal

ECMAScript type "Set" can be useful in schema

Motivation

there are many subdocument schema which should be unique within an individual document.

Example

const abcSchema= new Schema<abc>({
    name:{type:String, unique: true},
    keywords: Set(String)
})

alanpurple avatar Jan 17 '23 06:01 alanpurple