prorm API Reference
    Preparing search index...

    Interface DistanceOptions

    Options for distance calculations

    interface DistanceOptions {
        from: string | { type: GeometryType; coordinates: number[] };
        distance: number;
        spheroid?: boolean;
        srid?: number;
    }
    Index
    from: string | { type: GeometryType; coordinates: number[] }

    The point/geometry to measure distance from

    distance: number

    The maximum distance (in meters for geography, units depend on CRS for geometry)

    spheroid?: boolean

    Use spheroidal calculation (PostgreSQL geography, default: true)

    srid?: number

    SRID for the calculation (default: 4326)