I am using mongodb node js driver in my backend services. I use typescript in all my service . The latest version of nodejs driver doesn’t provide solid type definitions for aggregation pipelines.
Anyone using VS code will benefit greatly from these definitions getting useful auto completion and details about the.
The definitions are available from the mongoose library . However it should be native to the node js library