vue全局变量apiurl
1、定义
在main.js里面定义
Vue.prototype.$apiUrl = " http://xxxxxxxxxx";
2、使用
在联调的时候
url: this.$apiUrl + "/xxxx(端口)"
- 上一篇 »python 引用全局变量之global
- 下一篇 »>之避免使用全局变量
1、定义
在main.js里面定义
Vue.prototype.$apiUrl = " http://xxxxxxxxxx";
2、使用
在联调的时候
url: this.$apiUrl + "/xxxx(端口)"