vue 公共方法

1.新建commonjs文件夹,在里面新建index.js

2.commonjs/index.js,公共方法如下:

3.main.js中引入

4.页面中调用

posted @ 2019-09-04 14:29  董七  阅读(736)  评论(0编辑  收藏  举报