main.js默认生成 new Vue({ router, store, render: h => h(App) }).$mount('#app') ----- vue-cli3案例的里main.js --------- const app = new Vue({ components: { App, }, render: h => h(App), }); window.mountApp = () => { app.$mount('#app'); }; if (process.env.NODE_ENV === 'production') { if (window.STYLE_READY) { window.mountApp(); } } else { window.mountApp(); }