How to handle events in Vue js

In this article,we will understand about calling events inside vuejs. The event calling is one of the important concept in any programming language. The normal events are click events,change events etc.

Handling events in Vuejs:

The event handling in Vuejs can be explained clearly by the following example.
Scenario: Let us take this example,on click of button we need to display the name.

<script type=text/javascript src=js/vue.js><script>
<div id=dvevents>

<button v-on:click="displayname">< Display Me br>
<script type=text/javascript>
var vm=new vue({
    data: {	
                  return this.Name;

In the above example, we have on 'DisplayMe' button, the user clicks here to see his name.When user clicks button it calls 'DisplayMe' function there it will return the name given in the data section.

Happy Vue Coding !!!