smeijer / leaflet-geosearch

A geocoding/address-lookup library supporting various api providers.
https://smeijer.github.io/leaflet-geosearch/
MIT License
1.04k stars 273 forks source link

Module '"D:/www/free-border/node_modules/@types/leaflet/index"' has no default export. #280

Closed lookMyCode closed 3 years ago

lookMyCode commented 3 years ago

ERROR in node_modules/leaflet-geosearch/dist/SearchControl.d.ts:1:8 - error TS1192: Module '"D:/www/free-border/node_modules/@types/leaflet/index"' has no default export.

1 import L, { ControlPosition, FeatureGroup, MarkerOptions, Map } from 'leaflet'; ~

Hi! I have this problem! Please fix in replacing import import L, { ControlPosition, FeatureGroup, MarkerOptions, Map } from 'leaflet' to

import * as L from 'leaflet';
import { ControlPosition, FeatureGroup, MarkerOptions, Map } from 'leaflet';

or simular way.

Thank you!

smeijer commented 3 years ago

This isn't the repo for leafletjs. Please report issues with leaflet in their repo at https://github.com/Leaflet/Leaflet