interface Map {
    $map: {
        as?: string;
        in: any;
        input: ArrayExpression<any>;
    };
}

Properties

Properties

$map: {
    as?: string;
    in: any;
    input: ArrayExpression<any>;
}

Applies a subexpression to each element of an array and returns the array of resulting values in order. Accepts named parameters.

Type declaration

  • Optional as?: string

    A name for the variable that represents each individual element of the input array. If no name is specified, the variable name defaults to this.

  • in: any

    An expression that is applied to each element of the input array. The expression references each element individually with the variable name specified in as.

  • input: ArrayExpression<any>

    An expression that resolves to an array.