Hi, I'm using Mongoose with NestJS and trying to serialize my documents in the response using class-transformer. The problem is that Mongoose doesn't return class instances, so class-transformer doesn't work as expected (e.g., @Expose() decorators are ignored).
What is the recommended way to properly serialize Mongoose documents so that they work with class-transformer? Is there a clean way to convert them to class instances before returning from a controller?
Any official or community best practice for this?
Thanks!