Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unknown types #13

Open
fdorantesm opened this issue Jan 23, 2021 · 1 comment
Open

Unknown types #13

fdorantesm opened this issue Jan 23, 2021 · 1 comment

Comments

@fdorantesm
Copy link

node_modules/mongoose-softdelete/index.d.ts:1:42 - error TS2305: Module '"mongoose"' has no exported member 'DocumentQuery'.

1 import { Document, Model, Query, Schema, DocumentQuery } from "mongoose";
                                           ~~~~~~~~~~~~~

node_modules/mongoose-softdelete/index.d.ts:15:38 - error TS2314: Generic type 'Query<ResultType, DocType>' requires 2 type argument(s).

15   isDeleted: (condition: Boolean) => Query<ISoftDeletedDocument>;
                                        ~~~~~~~~~~~~~~~~~~~~~~~~~~~

node_modules/mongoose-softdelete/index.d.ts:18:33 - error TS2314: Generic type 'Query<ResultType, DocType>' requires 2 type argument(s).

18 export type ISoftDeletedQuery = Query<ISoftDeletedDocument> & IQueryMethods;
                                   ~~~~~~~~~~~~~~~~~~~~~~~~~~~

[3:54:37 PM] Found 3 errors. Watching for file changes.
@msrumon
Copy link

msrumon commented Jan 27, 2021

@fdorantesm Change line 15 like this:

isDeleted: (condition: boolean) => Query<boolean, ISoftDeletedDocument>;

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants