Skip to content
Effect 4.0 is here. One ecosystem. Zero dependencies.

Geolocation

9 exports Since v1.0.0 Source

Accessors

Signature

declare function watchPosition(options?: PositionOptions & {
readonly bufferSize?: number;
}): Stream<GeolocationPosition, GeolocationError, Geolocation>

Errors

Signature

declare class GeolocationError extends any {
constructor();
message: any;
}

Layers

Since v1.0.0

Signature

declare const layer: Layer.Layer<Geolocation>

Models

Geolocation

interface
Since v1.0.0

Signature

interface Geolocation {
readonly [TypeId]: typeof TypeId;
readonly getCurrentPosition: (options?: PositionOptions) => Effect<GeolocationPosition, GeolocationError>;
readonly watchPosition: (options?: PositionOptions & {
readonly bufferSize?: number;
}) => Stream<GeolocationPosition, GeolocationError>;
}

Tags

Signature

declare const Geolocation: Tag<Geolocation, Geolocation>

Type Ids

Signature

declare const ErrorTypeId: unique symbol
Since v1.0.0

Signature

type ErrorTypeId = typeof ErrorTypeId
Since v1.0.0

Signature

declare const TypeId: unique symbol
Since v1.0.0

Signature

type TypeId = typeof TypeId