{"action":"created","issue":{"url":"https://api.github.com/repos/Starcounter/Starcounter/issues/3191","repository_url":"https://api.github.com/repos/Starcounter/Starcounter","labels_url":"https://api.github.com/repos/Starcounter/Starcounter/issues/3191/labels{/name}","comments_url":"https://api.github.com/repos/Starcounter/Starcounter/issues/3191/comments","events_url":"https://api.github.com/repos/Starcounter/Starcounter/issues/3191/events","html_url":"https://github.com/Starcounter/Starcounter/issues/3191","id":122477132,"number":3191,"title":"How to trigger a json dirtyCheck?","user":{"login":"ivarbergman","id":112064,"avatar_url":"https://avatars.githubusercontent.com/u/112064?v=3","gravatar_id":"","url":"https://api.github.com/users/ivarbergman","html_url":"https://github.com/ivarbergman","followers_url":"https://api.github.com/users/ivarbergman/followers","following_url":"https://api.github.com/users/ivarbergman/following{/other_user}","gists_url":"https://api.github.com/users/ivarbergman/gists{/gist_id}","starred_url":"https://api.github.com/users/ivarbergman/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ivarbergman/subscriptions","organizations_url":"https://api.github.com/users/ivarbergman/orgs","repos_url":"https://api.github.com/users/ivarbergman/repos","events_url":"https://api.github.com/users/ivarbergman/events{/privacy}","received_events_url":"https://api.github.com/users/ivarbergman/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"milestone":null,"comments":2,"created_at":"2015-12-16T10:52:47Z","updated_at":"2016-04-21T14:09:49Z","closed_at":"2016-04-21T14:09:49Z","body":"Hi! \r\n\r\nAs far as I can see the  [json-patch-duplex.ts](https://github.com/Starcounter-Jack/JSON-Patch/blob/master/src/json-patch-duplex.ts)  performs a dirtyCheck either on mouse/key events or on a timeout basis.\r\n\r\nThis results in a annoying delay in some parts of our apps when the json data is changed without any user mouse/key activities. \r\n\r\nAre the some recommended ways to explicitly force a dirtyCheck? Or will this be reworked in the near future. Today I use:\r\n\r\n    var clickEvent = document.createEvent ('MouseEvents');\r\n    clickEvent.initEvent (\"mousedown\", true, true);\r\n    window.dispatchEvent (clickEvent);\r\n"},"comment":{"url":"https://api.github.com/repos/Starcounter/Starcounter/issues/comments/212936325","html_url":"https://github.com/Starcounter/Starcounter/issues/3191#issuecomment-212936325","issue_url":"https://api.github.com/repos/Starcounter/Starcounter/issues/3191","id":212936325,"user":{"login":"warpech","id":566463,"avatar_url":"https://avatars.githubusercontent.com/u/566463?v=3","gravatar_id":"","url":"https://api.github.com/users/warpech","html_url":"https://github.com/warpech","followers_url":"https://api.github.com/users/warpech/followers","following_url":"https://api.github.com/users/warpech/following{/other_user}","gists_url":"https://api.github.com/users/warpech/gists{/gist_id}","starred_url":"https://api.github.com/users/warpech/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/warpech/subscriptions","organizations_url":"https://api.github.com/users/warpech/orgs","repos_url":"https://api.github.com/users/warpech/repos","events_url":"https://api.github.com/users/warpech/events{/privacy}","received_events_url":"https://api.github.com/users/warpech/received_events","type":"User","site_admin":false},"created_at":"2016-04-21T14:09:49Z","updated_at":"2016-04-21T14:09:49Z","body":"@ivarbergman this is absolutely right approach. I would only change `mousedown` to `mouseup`, because we might dump `mousedown` on some point (see https://github.com/Starcounter-Jack/JSON-Patch/issues/98)\r\n\r\nI have explained the approach you took in PuppetJs README: https://github.com/PuppetJs/PuppetJs/blob/gh-pages/README.md#generating-patches-based-on-local-changes\r\n\r\nA high level API is discussed in https://github.com/PuppetJs/PuppetJs/issues/29"}}