如图,后面的版本号根据自己喜欢的来写。
执行npm install安装,完成后node_modules目录下生成了vue-resource文件夹
npm install
将vue-resource导入到main.js中并全局注册
这里要提前准备好接收请求的接口或者mock数据