Skip to content

Commit 5fb42b4

Browse files
committed
docs(typescript): correct schema and model generic params in TS virtuals docs
Fix mongoosejs/mongoose-lean-virtuals#74
1 parent b1ac0f5 commit 5fb42b4

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

docs/typescript/virtuals.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -72,9 +72,9 @@ interface UserVirtuals {
7272
fullName: string;
7373
}
7474

75-
type UserModel = Model<UserDoc, {}, UserVirtuals>; // <-- add virtuals here...
75+
type UserModel = Model<UserDoc, {}, {}, UserVirtuals>; // <-- add virtuals here...
7676

77-
const schema = new Schema<UserDoc, UserModel, UserVirtuals>({ // <-- and here
77+
const schema = new Schema<UserDoc, UserModel, {}, {}, UserVirtuals>({ // <-- and here
7878
firstName: String,
7979
lastName: String
8080
});

0 commit comments

Comments
 (0)