How to access VUE instance in vue-router?
淡淡烟草味
淡淡烟草味 2017-05-19 10:24:34
0
1
1059

As shown in the picture, vue-router is used in the project and placed under the path in the picture

/router/index.js introduces Vue and vue-router

import Vue from 'vue'
import Router from 'vue-router'

There is a Vue.prototype.debug = true defined in main.js

Now I want to know how to access the Vue.prototype.debug object in /router/index.js?

淡淡烟草味
淡淡烟草味

reply all(1)
黄舟

I don’t know how to deal with your problem.
My way to save the country is: define a config.js, declare it in itexport const APP_DEBUG_MODE = true, and then introduce this config to determine the value of APP_DEBUG_MODE where you need to judge Vue.debug

Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template
About us Disclaimer Sitemap
php.cn:Public welfare online PHP training,Help PHP learners grow quickly!