Package version:

Defines a mapping between a field in a data source and a target field in an index.

interface FieldMapping {
    mappingFunction?: FieldMappingFunction;
    sourceFieldName: string;
    targetFieldName?: string;
}

Properties

mappingFunction?: FieldMappingFunction

A function to apply to each source field value before indexing.

sourceFieldName: string

The name of the field in the data source.

targetFieldName?: string

The name of the target field in the index. Same as the source field name by default.