We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
In typegoose, i want to no typing '{ virtuals : true }' but plugin can auto lean it. when i use the mongooseLeanDefaults, i can use
@plugin(mongooseLeanDefaults as any, { defaults: true }) @plugin(mongooseLeanVirtuals as any, { enabledByDefault: true, virtuals: true, lean: true, }) export class SyncBBRecord{ @prop({ default: 'default_name' }) name?: string; get vv() { return 'vv'; } } const result = await this.mSyncBBRecord.findOne({}).lean(); console.log(result.name); // name has default value. console.log(result.vv); // vv is virtuals.
the mongooseLeanDefaults plugin can auto lean, but mongooseLeanVirtuals cannot.
i hope mongooseLeanVirtuals can esay use just like use mongooseLeanDefaults .
The text was updated successfully, but these errors were encountered:
Okay, it turns out that the NPM package is not synchronized with the git warehouse. please republish the npm mongoose-lean-virtuals.
Sorry, something went wrong.
No branches or pull requests
In typegoose,
i want to no typing '{ virtuals : true }' but plugin can auto lean it.
when i use the mongooseLeanDefaults, i can use
the mongooseLeanDefaults plugin can auto lean,
but mongooseLeanVirtuals cannot.
i hope mongooseLeanVirtuals can esay use just like use mongooseLeanDefaults .
The text was updated successfully, but these errors were encountered: