Skip to content

Instantly share code, notes, and snippets.

Created July 17, 2017 17:22
Show Gist options
  • Save anonymous/142c3ef56ae3c33608557c5f179f2999 to your computer and use it in GitHub Desktop.
Save anonymous/142c3ef56ae3c33608557c5f179f2999 to your computer and use it in GitHub Desktop.
JS Bin // source http://jsbin.com/gunalobore
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width">
<title>JS Bin</title>
</head>
<body>
<img v-on:click="expand" src="https://upload.wikimedia.org/wikipedia/en/2/24/Lenna.png" id="app"/>
<script src="https://cdnjs.cloudflare.com/ajax/libs/vue/2.0.3/vue.js"></script>
<script id="jsbin-javascript">
app = new Vue({
el: '#app',
data: {},
methods: {
expand(event ){
console.log(event.clientX );
console.log(event.clientY);
}
}
});
</script>
<script id="jsbin-source-javascript" type="text/javascript">app = new Vue({
el: '#app',
data: {},
methods: {
expand(event ){
console.log(event.clientX );
console.log(event.clientY);
}
}
});</script></body>
</html>
app = new Vue({
el: '#app',
data: {},
methods: {
expand(event ){
console.log(event.clientX );
console.log(event.clientY);
}
}
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment