-
-
Notifications
You must be signed in to change notification settings - Fork 3.9k
Open
Labels
developer-experienceThis issue improves error messages, debugging, or reportingThis issue improves error messages, debugging, or reportingdocsThis issue is due to a mistake or omission in the mongoosejs.com documentationThis issue is due to a mistake or omission in the mongoosejs.com documentationenhancementThis issue is a user-facing general improvement that doesn't fix a bug or add a new featureThis issue is a user-facing general improvement that doesn't fix a bug or add a new featuretypescriptTypes or Types-test related issue / Pull RequestTypes or Types-test related issue / Pull Request
Description
Prerequisites
- I have written a descriptive issue title
- I have searched existing issues to ensure the feature has not already been requested
🚀 Feature Proposal
I'm trying to port a JS project that uses loadClass to TS (it's doing my head in trying to get types working completely ..). The documentation on TS is good enough, except doesn't mention anything about loadClass. A basic example showing how to use it with Mongoose's typings, or alternatively, a statement recommending against its use, and briefly why would be helpful.
Aside: the fundamental class structure implied by loadClass seems to be at odds with Mongoose's actual class structure. Maybe this wasn't a problem in JS work, but it's definitely, at the least, a bit confusing in TS world. Maybe loadClass should be deprecated.
Motivation
Help users trying to decide whether to try shoehorn loadClass into Mongoose typings or not.
Example
No response
Metadata
Metadata
Assignees
Labels
developer-experienceThis issue improves error messages, debugging, or reportingThis issue improves error messages, debugging, or reportingdocsThis issue is due to a mistake or omission in the mongoosejs.com documentationThis issue is due to a mistake or omission in the mongoosejs.com documentationenhancementThis issue is a user-facing general improvement that doesn't fix a bug or add a new featureThis issue is a user-facing general improvement that doesn't fix a bug or add a new featuretypescriptTypes or Types-test related issue / Pull RequestTypes or Types-test related issue / Pull Request