DEV Community

Discussion on: How To Build a Todo App with React, TypeScript, NodeJS, and MongoDB

Collapse
 
hedwardd profile image
Heath Daniel

@ibrahima92 Not sure how familiar you are with this but I'm curious what you make of Mongoose's documentation not recommending that your interfaces extend Document? E.g., interface ITodo extends Document

The reason they gave is

Using extends Document makes it difficult for Mongoose to infer which properties are present on query filters, lean documents, and other cases.

Thanks!