{"action":"opened","issue":{"url":"https://api.github.com/repos/w8r/Leaflet.Path.Drag/issues/37","repository_url":"https://api.github.com/repos/w8r/Leaflet.Path.Drag","labels_url":"https://api.github.com/repos/w8r/Leaflet.Path.Drag/issues/37/labels{/name}","comments_url":"https://api.github.com/repos/w8r/Leaflet.Path.Drag/issues/37/comments","events_url":"https://api.github.com/repos/w8r/Leaflet.Path.Drag/issues/37/events","html_url":"https://github.com/w8r/Leaflet.Path.Drag/issues/37","id":362003148,"node_id":"MDU6SXNzdWUzNjIwMDMxNDg=","number":37,"title":"Values not updating on target on event drag","user":{"login":"perseus086","id":5582569,"node_id":"MDQ6VXNlcjU1ODI1Njk=","avatar_url":"https://avatars3.githubusercontent.com/u/5582569?v=4","gravatar_id":"","url":"https://api.github.com/users/perseus086","html_url":"https://github.com/perseus086","followers_url":"https://api.github.com/users/perseus086/followers","following_url":"https://api.github.com/users/perseus086/following{/other_user}","gists_url":"https://api.github.com/users/perseus086/gists{/gist_id}","starred_url":"https://api.github.com/users/perseus086/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/perseus086/subscriptions","organizations_url":"https://api.github.com/users/perseus086/orgs","repos_url":"https://api.github.com/users/perseus086/repos","events_url":"https://api.github.com/users/perseus086/events{/privacy}","received_events_url":"https://api.github.com/users/perseus086/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":0,"created_at":"2018-09-20T03:19:04Z","updated_at":"2018-09-20T03:19:04Z","closed_at":null,"author_association":"NONE","body":"I need to get the center of a rectangle while dragging.\r\n\r\nI've tried the following:\r\n```\r\nvar rectangle = new L.Rectangle([...], { draggable: true }).addTo(map);\r\n//Copy from here\r\nrectangle.on('drag', function(event){\r\n   console.log('on drag', event.target.getCenter());\r\n})\r\n\r\nrectangle.on('dragend', function(event){\r\n   console.log('on dragend', event.target.getCenter());\r\n})\r\n```\r\n\r\nOn **dragend** it works. But on **drag** it is not working.\r\n\r\nProblem appears with polyline, polygon and rectangle.\r\n\r\nWe can reproduce the issue by adding previous lines (from comment //Copy from here) on console of the browser here: http://w8r.name/Leaflet.Path.Transform/example/ and moving the rectangle.\r\n"}}
{"actor":{"display_login":"perseus086"}}