{"action":"created","issue":{"url":"https://api.github.com/repos/dbushell/Pikaday/issues/429","labels_url":"https://api.github.com/repos/dbushell/Pikaday/issues/429/labels{/name}","comments_url":"https://api.github.com/repos/dbushell/Pikaday/issues/429/comments","events_url":"https://api.github.com/repos/dbushell/Pikaday/issues/429/events","html_url":"https://github.com/dbushell/Pikaday/issues/429","id":112570685,"number":429,"title":"Throw exception, if Pikaday is initialize twice using the same Element","user":{"login":"j6s","id":3374170,"avatar_url":"https://avatars.githubusercontent.com/u/3374170?v=3","gravatar_id":"","url":"https://api.github.com/users/j6s","html_url":"https://github.com/j6s","followers_url":"https://api.github.com/users/j6s/followers","following_url":"https://api.github.com/users/j6s/following{/other_user}","gists_url":"https://api.github.com/users/j6s/gists{/gist_id}","starred_url":"https://api.github.com/users/j6s/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/j6s/subscriptions","organizations_url":"https://api.github.com/users/j6s/orgs","repos_url":"https://api.github.com/users/j6s/repos","events_url":"https://api.github.com/users/j6s/events{/privacy}","received_events_url":"https://api.github.com/users/j6s/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"milestone":null,"comments":2,"created_at":"2015-10-21T11:55:42Z","updated_at":"2015-11-13T11:10:09Z","closed_at":"2015-11-13T10:59:16Z","body":"If (on accident) Pikaday is initialized twice for a single DOM Element, the two instances will create a loop, firing change events back and forth (and not stopping, because `e.firedBy` is not `self`). \r\n\r\nGranted, the fault in this case is not in the Library, but in the developer using the Library, but simply throwing an exception, if a user tries to initialize Pikaday multiple times on the same Element would make debugging easier"},"comment":{"url":"https://api.github.com/repos/dbushell/Pikaday/issues/comments/156399699","html_url":"https://github.com/dbushell/Pikaday/issues/429#issuecomment-156399699","issue_url":"https://api.github.com/repos/dbushell/Pikaday/issues/429","id":156399699,"user":{"login":"j6s","id":3374170,"avatar_url":"https://avatars.githubusercontent.com/u/3374170?v=3","gravatar_id":"","url":"https://api.github.com/users/j6s","html_url":"https://github.com/j6s","followers_url":"https://api.github.com/users/j6s/followers","following_url":"https://api.github.com/users/j6s/following{/other_user}","gists_url":"https://api.github.com/users/j6s/gists{/gist_id}","starred_url":"https://api.github.com/users/j6s/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/j6s/subscriptions","organizations_url":"https://api.github.com/users/j6s/orgs","repos_url":"https://api.github.com/users/j6s/repos","events_url":"https://api.github.com/users/j6s/events{/privacy}","received_events_url":"https://api.github.com/users/j6s/received_events","type":"User","site_admin":false},"created_at":"2015-11-13T11:10:09Z","updated_at":"2015-11-13T11:10:09Z","body":"You can see what I am describing very clearly in this pen: http://codepen.io/thephpjo/pen/pjqavp\r\n\r\nIf you select a date and have a look in the devtools you will see the instances `ping`ing and `pong`ing the event back and forth until the loop is stopped because the max callstack size was exceeded "}}