vue use this inside function
<script>
export default {
mounted() {
this.myMethod()
},
methods:{
myMethod() {
window.addEventListener('click', function() {
console.log('this scope (vuejs) >', this)
}.bind(this))
}
}
}
</script>