All notable changes to this project will be documented in this file.
The format is based on Keep a Changelog, and this project adheres to Semantic Versioning.
- New custom reactivity. This improves performance to be nearly identical to vanilla mapbox, while retaining full* Vue reactivity on the map
- Update Mapbox to
3.4.0
- Update Geocoder to
5.1.0
, adds V6 api support
- Fixed
Invalid watch source
on markers
- Added style.load & style.import.load events
- fix attribution control
- Various updates including mapbox-gl 3.1
- Fixed layer watch type errors
- Add reactivity to layers
Special thanks to Jason Hibbs
- Fixed navigation & scale control
- Marker latlng reactivity fix
- Marker latlng reactivity improvement
- Duplicate id/key initialization check & warning
- Geocoder type import fix
- DefaultMarker custom HTML slot
- Setting marker latlng when passing HTML ref
- RTLTextPlugin support
- Runtime Config support
- Map geocoder events, ref access & v-model
- New documentation site
- Passing map container html instead of id
- Passing HTML element to popup with
setDOMContent
- Updated type imports for Nuxt 3.8.0
- Better bundling output (no more global plugin)
- Fixed geocoder import issue (#61)
- Fixed Marker latlng drag reactivity
- Geocoder v-model clear fix
useMapboxPopup
now is called after HTML is put in DOM
- Geocoder import fix
- ESModule import fix
- Custom geocoder missing import fix
- Defining source in layer is now deprecated
- Old
useMapbox
now nameduseMapboxBeforeLoad
for people using v1.3.4 defineMapboxMarker
&defineMapboxPopup
now acceptoptions
as a ref, providing full reactivity.useMapboxMarker
&useMapboxPopup
composables- Popup HTML is now reactive to changes
- Auto map resizing
- Better named
useMapboxRef
function instead ofuseMapboxInstance
- Marker
dragend
fix - Fixed layer & source reloading
- Removed
script
import from CDN usingas default
and dynamic imports
- Fixed bug when
source
is removed beforelayer
- Removed unnecessary
mapboxgl
from geocoder options
- beforeLayer prop for layers so you can ensure proper layer order
- Fixed markers getting added with no latlng
- Fixed useMapbox not getting called while sources/layers are loading
- Fixed performance issues with many layers
- (Only adding map event listeners when events are actually being used)
- useMapbox always fires properly
- Custom geocoder import
- Fixed controls not loading
- Custom geocoder (Lets you use your own inputs outside of a map)
- Allowed geocoder to be placed outside map
- Deleting sources & controls when component is removed
- Reacting to prop changes for Popups & Markers
- Updated Nuxt to 3.5.0
- Added
persistent
option sokeepalive
can properly be disabled
- Made
source-id
in layer optional
- Fixed bug with style url
- Setting
keepalive
to true so persistent maps is enabled by default.
- Persistent Map Instances
- Ability to attach Popup to Marker with slot
- Position prop for controls
- defineMapboxControl for custom controls
- Fixed bug with map instances not being cleaned up.
- Made sure map controls & layers only get added on mount (probably unnecessary with useMapbox).
- Popup & Marker events
- Passed Map instance to certain Map events so you dont need useMapbox
- Default 'options' prop so you dont need to pass empty object
- Events directly on layer components
- BREAKING:
apiKey
renamed toaccessToken
to match mapbox - Renamed _useMapboxInstance to useMapboxInstance
- Extended config options
- Component events from mapbox
- Exposed defineMapboxInstance for custom map components
- Fixed
Map markers are disabled.
with geocoder
- Import fix
- Default Popup & Marker components
- defineMapboxMarker & defineMapboxPopup for easily making custom components
- New syntax for useMapbox with callback
- Added Geocoder Control