[Vuejs]-Passing props in vue

0👍

You cannot have both data and props with the same name. Remove event from your data. And you can give a default value of your props as follow.

props : {
   ...
   event : {
       type : 'Object',
       default : function(){
           return {
               name : ''
               // and other fields
           };
       }
   }
}

Leave a comment