Skip to content
This repository has been archived by the owner on Mar 28, 2022. It is now read-only.

Cannot set property 'labelVersion' of undefined #161

Open
kansi opened this issue Jul 27, 2016 · 3 comments
Open

Cannot set property 'labelVersion' of undefined #161

kansi opened this issue Jul 27, 2016 · 3 comments

Comments

@kansi
Copy link

kansi commented Jul 27, 2016

Leaflet version: 0.7.7
Leaflet-label: 0.2.1-0

I have installed both from npm. When i try to use leaflet-label by using import 'leaflet-label' it gives the following error

Uncaught TypeError: Cannot set property 'labelVersion' of undefined

I import leaflet before importing leaflet-label. Any clues on what might be the issue.

@aparij
Copy link

aparij commented Sep 1, 2016

got the same error. Looks like the npm version is too old.
#101

Do :
npm i --save Leaflet/Leaflet.label

and
import 'leaflet.label';

@abhisheksaini333
Copy link

But this does not help as well I get "Uncaught TypeError: layer.bindLabel is not a function" inside function onEachFeature(feature, layer) { --- }

@1Jesper1
Copy link

@aparij Thanks, do you know what the difference is between https://www.npmjs.com/package/leaflet-label and https://www.npmjs.com/package/leaflet.label, seems leaflet.label has a more recent version?

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants