diff --git a/types/react-map-gl/index.d.ts b/types/react-map-gl/index.d.ts index 2260644d32..1f459fdb96 100644 --- a/types/react-map-gl/index.d.ts +++ b/types/react-map-gl/index.d.ts @@ -23,20 +23,20 @@ export interface MapError { export interface MapRequest { url: string; - headers: {}; - credentials: string; + headers?: { [index: string]: string }; + credentials?: string; } export interface MapboxProps extends Partial { container?: {}; - mapboxApiAccessToken: string; + mapboxApiAccessToken?: string; attributionControl?: boolean; preserveDrawingBuffer?: boolean; onLoad?: () => void; onError?: (e: MapError) => void; resuseMaps?: boolean; resuseMap?: boolean; - transformRequest?: () => MapRequest; + transformRequest?: (url?: string, resourceType?: string) => MapRequest; mapStyle?: string | {};