-
-
Notifications
You must be signed in to change notification settings - Fork 3.8k
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
Setters property of schema types not available in TS declarations #14879
Milestone
Comments
vkarpov15
added a commit
that referenced
this issue
Sep 11, 2024
types: make SchemaType static `setters` property accessible in TypeScript
This was referenced Oct 3, 2024
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Prerequisites
Mongoose version
8.6.1
Node.js version
20.13.1
MongoDB server version
7.0.8
Typescript version (if applicable)
5.5.2
Description
In #13538 , a new static
setters
property was added to several schema type classes as well as an instancesetters
property to the baseSchemaType
class. These properties are not available in the TS declaration files, so accessing the setters property is issuing a type error.Steps to Reproduce
Type error will occur on the access of the missing
setters
property.Expected Behavior
The
setters
property should allow pushing a setter function without type error.The text was updated successfully, but these errors were encountered: