[Vuejs]-Update Global Component data

0👍

You can try to use vue-script2

You will be able to access vue variables like in template.

<script2>
....
 this.on("success", function(file,albumImage) {

              var x = {{albumImages}}


            });
....
</script2>

Although it might not work. Other option would be to try load function in mounted. E.g.

import VS2 from 'vue-script2'
export default {
  name: 'freshchat',
  mounted() {
    VS2.load('yourdropzonejs script').then(() => {
           var vm = this
           .....
           this.on("success", function(file,albumImage) {

               vm.albumImages


            });

    })
  }
}

Leave a comment