Created
June 14, 2017 18:11
-
-
Save hendrikswan/48f87d07d94f0a7ce3964ff24f3a48a4 to your computer and use it in GitHub Desktop.
code samples for medium post
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function syncMouseEvent(event) { | |
api.syncEvent({ | |
x: event.clientX, | |
y: event.clientY | |
}) | |
.then((result) => { | |
console.log('successfully synced a mouse event'); | |
}) | |
.catch((reason) => { | |
console.error('got an error while trying to sync an event') | |
}); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment