node.js – NestJS mongoose schema with array of schema doesn’t populate virtual id
I have the following schema export type MapDocument = Map & Document @Schema({ timestamps: true, versionKey: false, id: true }) export class Map { constructor(partial?: Partial<Map>) { if (partial) Object.assign(this, partial) } @IsOptional() @IsUUID() @Prop({ type: Object, default: uuidv4, required: false}) @Exclude({ toPlainOnly: true }) _id?: Object @ApiPropertyOptional({ type: String, format: ‘uuid’ }) @IsOptional() @IsUUID() … Read more