{"action":"created","issue":{"url":"https://api.github.com/repos/KRDS/kite.js/issues/3","labels_url":"https://api.github.com/repos/KRDS/kite.js/issues/3/labels{/name}","comments_url":"https://api.github.com/repos/KRDS/kite.js/issues/3/comments","events_url":"https://api.github.com/repos/KRDS/kite.js/issues/3/events","html_url":"https://github.com/KRDS/kite.js/pull/3","id":105629341,"number":3,"title":"Added busy flag","user":{"login":"vishnu-ravi","id":8384853,"avatar_url":"https://avatars.githubusercontent.com/u/8384853?v=3","gravatar_id":"","url":"https://api.github.com/users/vishnu-ravi","html_url":"https://github.com/vishnu-ravi","followers_url":"https://api.github.com/users/vishnu-ravi/followers","following_url":"https://api.github.com/users/vishnu-ravi/following{/other_user}","gists_url":"https://api.github.com/users/vishnu-ravi/gists{/gist_id}","starred_url":"https://api.github.com/users/vishnu-ravi/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/vishnu-ravi/subscriptions","organizations_url":"https://api.github.com/users/vishnu-ravi/orgs","repos_url":"https://api.github.com/users/vishnu-ravi/repos","events_url":"https://api.github.com/users/vishnu-ravi/events{/privacy}","received_events_url":"https://api.github.com/users/vishnu-ravi/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":3,"created_at":"2015-09-09T16:07:29Z","updated_at":"2015-09-09T17:22:57Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/KRDS/kite.js/pulls/3","html_url":"https://github.com/KRDS/kite.js/pull/3","diff_url":"https://github.com/KRDS/kite.js/pull/3.diff","patch_url":"https://github.com/KRDS/kite.js/pull/3.patch"},"body":"If I clicked the link twice the View.load function load the page twice in the container, so I have added the busy flag to check the state of ajax call to fix this issue."},"comment":{"url":"https://api.github.com/repos/KRDS/kite.js/issues/comments/138982597","html_url":"https://github.com/KRDS/kite.js/pull/3#issuecomment-138982597","issue_url":"https://api.github.com/repos/KRDS/kite.js/issues/3","id":138982597,"user":{"login":"ipernet","id":1324566,"avatar_url":"https://avatars.githubusercontent.com/u/1324566?v=3","gravatar_id":"","url":"https://api.github.com/users/ipernet","html_url":"https://github.com/ipernet","followers_url":"https://api.github.com/users/ipernet/followers","following_url":"https://api.github.com/users/ipernet/following{/other_user}","gists_url":"https://api.github.com/users/ipernet/gists{/gist_id}","starred_url":"https://api.github.com/users/ipernet/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ipernet/subscriptions","organizations_url":"https://api.github.com/users/ipernet/orgs","repos_url":"https://api.github.com/users/ipernet/repos","events_url":"https://api.github.com/users/ipernet/events{/privacy}","received_events_url":"https://api.github.com/users/ipernet/received_events","type":"User","site_admin":false},"created_at":"2015-09-09T17:22:57Z","updated_at":"2015-09-09T17:22:57Z","body":"e.g:\r\n\r\n```javascript\r\ndefine(['kite/view'], function(View)\r\n{\r\n\t$('#alink').click(function()\r\n\t{\r\n\t\tView.load('/some/url');\r\n\t});\r\n});\r\n\r\n// to\r\n\r\ndefine(['kite/view'], function(View)\r\n{\r\n\tvar busy = false;\r\n\r\n\t$('#alink').click(function(e)\r\n\t{\r\n\t\tif(busy) {\r\n\t\t\te.preventDefault();\r\n\t\t\treturn;\r\n\t\t}\r\n\r\n\t\tbusy = true;\r\n\r\n\t\tView.load({\r\n\t\t\tview: '/some/url',\r\n\t\t\tonRendered: function(){\r\n\t\t\t\tbusy = false;\r\n\t\t\t}\r\n\t\t});\r\n\t});\r\n});\r\n````"}}