{"action":"opened","issue":{"url":"https://api.github.com/repos/chmln/flatpickr/issues/420","repository_url":"https://api.github.com/repos/chmln/flatpickr","labels_url":"https://api.github.com/repos/chmln/flatpickr/issues/420/labels{/name}","comments_url":"https://api.github.com/repos/chmln/flatpickr/issues/420/comments","events_url":"https://api.github.com/repos/chmln/flatpickr/issues/420/events","html_url":"https://github.com/chmln/flatpickr/issues/420","id":190590513,"number":420,"title":"dateObj returns Array","user":{"login":"scottzirkel","id":1329131,"avatar_url":"https://avatars.githubusercontent.com/u/1329131?v=3","gravatar_id":"","url":"https://api.github.com/users/scottzirkel","html_url":"https://github.com/scottzirkel","followers_url":"https://api.github.com/users/scottzirkel/followers","following_url":"https://api.github.com/users/scottzirkel/following{/other_user}","gists_url":"https://api.github.com/users/scottzirkel/gists{/gist_id}","starred_url":"https://api.github.com/users/scottzirkel/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/scottzirkel/subscriptions","organizations_url":"https://api.github.com/users/scottzirkel/orgs","repos_url":"https://api.github.com/users/scottzirkel/repos","events_url":"https://api.github.com/users/scottzirkel/events{/privacy}","received_events_url":"https://api.github.com/users/scottzirkel/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":0,"created_at":"2016-11-20T22:58:43Z","updated_at":"2016-11-20T22:58:43Z","closed_at":null,"body":"I'm not sure if this is an issue with the code or with the docs, but in the docs under [formatDate](https://chmln.github.io/flatpickr/#api-formatDate) it says the dateObj returns an object, yet it's returning an array containing the object. When sending the object to be formatted, I have had to use `dateObj[0]` to make it work.\r\n\r\n```\r\nonChange(dateObj, dateStr, instance) {\r\n  newDate = instance.formatDate('Y-m-d', dateObj[0])\r\n}\r\n```\r\n\r\nAgain, that might be the intended result, but based on the docs, I would have expected dateObj to be only the dateObj."}}
{"actor":{"display_login":"scottzirkel"}}