nuxt-modules/leaflet

How to disable native zoom control?

Closed this issue · 2 comments

How to disable native zoom control without css method?
When create map in normal html, Leaflet has a zoomControl option.

https://leafletjs.com/reference.html#map-zoomcontrol

But it did not work when I set zoomControl prop in Lmap component.

Same problem with attributionControl.

I think the options props should be any legacy options that will be passed to the constructor of the corresponding leaflet object.

<template>
  <LMap
    :options="{
      // Any legacy leaflet option
     zoomControl: false
     attributionControl: false
    }"
  >
  </LMap>
</template>

Thanks for your answer, it works.