Skip to content

Commit

Permalink
feat(types): add id to MongooseOptions re: #11966
Browse files Browse the repository at this point in the history
  • Loading branch information
vkarpov15 committed Jul 19, 2022
1 parent 97a63a4 commit 80d1aaa
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions types/mongooseoptions.d.ts
Expand Up @@ -79,6 +79,9 @@ declare module 'mongoose' {
| stream.Writable
| ((collectionName: string, methodName: string, ...methodArgs: any[]) => void);

/** Defaults to `true`. If `true`, adds a `id` virtual to all schemas by default. */
id?: boolean;

/**
* If `false`, it will change the `createdAt` field to be [`immutable: false`](https://mongoosejs.com/docs/api/schematype.html#schematype_SchemaType-immutable)
* which means you can update the `createdAt`.
Expand Down

0 comments on commit 80d1aaa

Please sign in to comment.