第五章 配置axios 前端研究猿 2020-04-18 394 阅读1分钟 一、安装axios cnpm i axios --save 二、打开Home.vue 在script中加入 import axios from 'axios' methods:{ testAxios(){ axios.get('http://localhost:8080').then(res => { alert(res.data) }) } } 三、效果展示