# Leaflet.MovingMarker
**Repository Path**: lianggit/Leaflet.MovingMarker
## Basic Information
- **Project Name**: Leaflet.MovingMarker
- **Description**: 允许以自定义的持续时间沿多段线移动标记。
- **Primary Language**: Unknown
- **License**: MIT
- **Default Branch**: master
- **Homepage**: None
- **GVP Project**: No
## Statistics
- **Stars**: 0
- **Forks**: 0
- **Created**: 2025-08-08
- **Last Updated**: 2025-08-08
## Categories & Tags
**Categories**: Uncategorized
**Tags**: None
## README
Leaflet.MovingMarker
====================
----------
A Leaflet plug-in to create moving marker. Very useful to represent transportations or other movable things !
Demos
--------
Follow this link: [here](http://ewoken.github.io/Leaflet.MovingMarker)
Compatibility with Leaflet Versions
-----------------------------------
Compatible with the latest stable Leaflet version `leaflet-0.7.2`.
Browser Compatibility
-----------------------------------
This plugin internally uses ``` window.requestAnimationFrame``` through the Leaflet function ```L.Util.requestAnimFrame```
Features
--------
* Let move your markers along a polyline.
* You can zoom in/out, your moving marker will be at the right place !
* You can pause or end the animation whenever you want.
* You can deal with events.
* You can make **loop**.
* You can add the the point one by one.
* You can add *station* at some points of the polyline.
Usage
-----
Add this line to your HTML file:
```html
```
Then add your first MovingMarker:
```javascript
var myMovingMarker = L.Marker.movingMarker([[48.8567, 2.3508],[50.45, 30.523333]],
[20000]).addTo(map);
//...
myMovingMarker.start();
```
API
----
**Factory**
```
L.movingMarker( latlngs, durations [,