Skip to content
Nuxt module for leafletjs - https://schlunsen.github.io/nuxt-leaflet/
Branch: master
Clone or download
Rasmus Schlünsen
Rasmus Schlünsen Added LControl. Bump version
Latest commit 1ede0f8 Mar 28, 2019
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
example/nuxt-leaflet-example Added example nuxt project Mar 28, 2019
lib Added LControl. Bump version Mar 28, 2019
test Rebase Mar 13, 2018
.gitignore Update plugin file to reflect the new naming from vue2-leaflet. Repla… Apr 18, 2018
CHANGELOG.md chore(release): 0.1 Jan 18, 2019
LICENSE Rebase Mar 13, 2018
README.md Update README.md Mar 26, 2019
package-lock.json Bump version Mar 28, 2019
package.json Added LControl. Bump version Mar 28, 2019
yarn.lock Release fixes Jan 18, 2019

README.md

nuxt-leaflet

npm (scoped with tag) npm Dependencies js-standard-style

Nuxt module for leafletjs

📖 Release Notes

Features

Nuxt module for vue2-leaflet.

See vue2-leaflet for more details.

Setup

  • Add nuxt-leaflet dependency using yarn or npm to your project
  • Add nuxt-leaflet to modules section of nuxt.config.js
{
  modules: [
    // Simple usage
    'nuxt-leaflet',

    // With options
    ['nuxt-leaflet', { /* module options */ }],
 ]
}

Usage

Add the map to your page

<div id="map-wrap" style="height: 100vh">
 <no-ssr>
   <l-map :zoom=13 :center="[47.413220, -1.219482]">
     <l-tile-layer url="http://{s}.tile.osm.org/{z}/{x}/{y}.png"></l-tile-layer>
     <l-marker :lat-lng="[47.413220, -1.219482]"></l-marker>
   </l-map>
 </no-ssr>
</div>

The Leaflet 'L' object can be found on vue component: this.$L

List of currently implemented components

See components supported

Development

  • Clone this repository
  • Install dependnecies using yarn install or npm install
  • Start development server using npm run dev

License

MIT License

Copyright (c) Rasmus Schlunsen

You can’t perform that action at this time.