[Vuejs]-How to access component data outside export

0👍

I am not sure about if Vue has any limitations but from javascript point can’t you just do

 const data = {
   name: "App",  
   data() {
       return { 
         msg: "World"
      }  
   }

}

export default data;

const msg = app.data();

Leave a comment