{"action":"created","issue":{"url":"https://api.github.com/repos/Leaflet/Leaflet.draw/issues/253","labels_url":"https://api.github.com/repos/Leaflet/Leaflet.draw/issues/253/labels{/name}","comments_url":"https://api.github.com/repos/Leaflet/Leaflet.draw/issues/253/comments","events_url":"https://api.github.com/repos/Leaflet/Leaflet.draw/issues/253/events","html_url":"https://github.com/Leaflet/Leaflet.draw/issues/253","id":24792063,"number":253,"title":"Saving and restoring drawn objects","user":{"login":"grg9999","id":6265565,"avatar_url":"https://avatars.githubusercontent.com/u/6265565?v=3","gravatar_id":"","url":"https://api.github.com/users/grg9999","html_url":"https://github.com/grg9999","followers_url":"https://api.github.com/users/grg9999/followers","following_url":"https://api.github.com/users/grg9999/following{/other_user}","gists_url":"https://api.github.com/users/grg9999/gists{/gist_id}","starred_url":"https://api.github.com/users/grg9999/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/grg9999/subscriptions","organizations_url":"https://api.github.com/users/grg9999/orgs","repos_url":"https://api.github.com/users/grg9999/repos","events_url":"https://api.github.com/users/grg9999/events{/privacy}","received_events_url":"https://api.github.com/users/grg9999/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"milestone":null,"comments":8,"created_at":"2013-12-26T16:07:44Z","updated_at":"2015-06-22T15:39:48Z","closed_at":"2014-01-13T21:12:11Z","body":"Leaflet.draw is awesome, but I need to save and restore the drawn objects.\r\n\r\nI can get JSON for the layer by a somewhat cumbersome iteration in draw:created.\r\n\r\nBut I don't see an obvious way to go from JSON to objects on the map.\r\n\r\nSo two questions:\r\n\r\nIs there a built-in way to get JSON representation of the objects?\r\n\r\nIs there a way to go from JSON to objects on the may?\r\n\r\nThanks.\r\n"},"comment":{"url":"https://api.github.com/repos/Leaflet/Leaflet.draw/issues/comments/114157017","html_url":"https://github.com/Leaflet/Leaflet.draw/issues/253#issuecomment-114157017","issue_url":"https://api.github.com/repos/Leaflet/Leaflet.draw/issues/253","id":114157017,"user":{"login":"jbcoder","id":1719239,"avatar_url":"https://avatars.githubusercontent.com/u/1719239?v=3","gravatar_id":"","url":"https://api.github.com/users/jbcoder","html_url":"https://github.com/jbcoder","followers_url":"https://api.github.com/users/jbcoder/followers","following_url":"https://api.github.com/users/jbcoder/following{/other_user}","gists_url":"https://api.github.com/users/jbcoder/gists{/gist_id}","starred_url":"https://api.github.com/users/jbcoder/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jbcoder/subscriptions","organizations_url":"https://api.github.com/users/jbcoder/orgs","repos_url":"https://api.github.com/users/jbcoder/repos","events_url":"https://api.github.com/users/jbcoder/events{/privacy}","received_events_url":"https://api.github.com/users/jbcoder/received_events","type":"User","site_admin":false},"created_at":"2015-06-22T15:39:48Z","updated_at":"2015-06-22T15:39:48Z","body":"@AndriusGeo I am running into a similar issue on a project I'm working on. Perhaps you may be able to point me in the right direction. Currently, I'm using the ```toGeoJSON()``` function to save my drawn objects. However, GeoJSON doesn't seem to accommodate circles. What did you end up doing for those? Also, how did saving the styles end up going for you? Did you end up going with ```eachLayer()``` as you alluded to? Thanks!"}}