Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Toggle polygon #254

Open
jvaldezch opened this issue Jan 28, 2021 · 1 comment
Open

Toggle polygon #254

jvaldezch opened this issue Jan 28, 2021 · 1 comment

Comments

@jvaldezch
Copy link

Is there a way to toggle an specific polygon to show the popup content using JS code?
Thanks

@dpakprajul
Copy link

vt_layer.on('click', function (e) {
var properties = e.layer.properties;
L.popup()
.setContent("County: " + e.layer.properties.NAMELSAD10 + "
White Student: " + e.layer.properties.D01 + "
White Teacher: " + e.layer.properties.D02)
.setLatLng(e.latlng)
.openOn(map);

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

No branches or pull requests

2 participants