The scope of the Vue object

Code written by colleagues

function tableVue(tableData){
    var tableData = tableData;
    /* vue */
    var tableV = new Vue({  
        el: "-sharptable",
        data: {
            item:[]
        },
        mounted: function () {
            // 
            this.item = tableData;
        }
    });
}

then call this tableVue function when the page is initialized, and it works. But isn"t this tableV a local variable? Won"t virtual DOM nodes be destroyed with the destruction of this variable?


the virtual DOM node references the tableData, so if the virtual DOM node is not destroyed, the tableData will not be destroyed.

so there is no logic like tableData destruction, virtual dom destruction.

MySQL Query : SELECT * FROM `codeshelper`.`v9_news` WHERE status=99 AND catid='6' ORDER BY rand() LIMIT 5
MySQL Error : Disk full (/tmp/#sql-temptable-64f5-1bbdca5-453e8.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
MySQL Errno : 1021
Message : Disk full (/tmp/#sql-temptable-64f5-1bbdca5-453e8.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
Need Help?