mongoose 6.6.7 → 6.7.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -10,6 +10,7 @@ declare module 'mongoose' {
10
10
  | PipelineStage.Count
11
11
  | PipelineStage.Densify
12
12
  | PipelineStage.Facet
13
+ | PipelineStage.Fill
13
14
  | PipelineStage.GeoNear
14
15
  | PipelineStage.GraphLookup
15
16
  | PipelineStage.Group
@@ -90,6 +91,16 @@ declare module 'mongoose' {
90
91
  }
91
92
  }
92
93
 
94
+ export interface Fill {
95
+ /** [`$fill` reference](https://docs.mongodb.com/manual/reference/operator/aggregation/fill/) */
96
+ $fill: {
97
+ partitionBy?: Expression,
98
+ partitionByFields?: string[],
99
+ sortBy?: Record<string, 1 | -1>,
100
+ output: Record<string, { value: Expression } | { method: 'linear' | 'locf' }>
101
+ }
102
+ }
103
+
93
104
  export interface Facet {
94
105
  /** [`$facet` reference](https://docs.mongodb.com/manual/reference/operator/aggregation/facet/) */
95
106
  $facet: Record<string, FacetPipelineStage[]>;
@@ -57,7 +57,7 @@ declare module 'mongoose' {
57
57
  T | typeof SchemaType | Schema<any, any, any> | SchemaDefinition<T> | Function | AnyArray<Function>;
58
58
 
59
59
  /** Defines a virtual with the given name that gets/sets this path. */
60
- alias?: string;
60
+ alias?: string | string[];
61
61
 
62
62
  /** Function or object describing how to validate this schematype. See [validation docs](https://mongoosejs.com/docs/validation.html). */
63
63
  validate?: SchemaValidator<T> | AnyArray<SchemaValidator<T>>;