[Vuejs]-Vue @click event is not working in my version of Edge

0👍

Why void?

The most common way:

   test: function() {
      console.log('test');
   }

And you call it with @click="test"

and i hope you putted everything inside methods

    methods:{
       test: function() {
          console.log('test');
       }
    }

0👍

You could refer to this guide about listening to click events in vue.js. I made a sample to show how to make console.log() work in vue.js, you could refer to it. You could also test it in Edge and it works well in my Edge 44.18362.1.0:

var example = new Vue({
  el: '#example',
  methods: {
    test: function() {
      console.log('test');
    }
  }
})
<script src="https://cdnjs.cloudflare.com/ajax/libs/vue/2.5.17/vue.js"></script>
<div id="example">
  <button @click="test">test</button>
</div>

Leave a comment