CountPrice:function(){
// GET /someUrl
this.$http.get('CardboardPrice.json').then((response) => {
alert(1);
}, (response) => {
// error callback
});
}
浏览器支持本地ajax。可以弹出1。
问:获取的json的如何进行处理,response 只显示对象。
CountPrice:function(){
// GET /someUrl
this.$http.get('CardboardPrice.json').then((response) => {
alert(1);
}, (response) => {
// error callback
});
}
浏览器支持本地ajax。可以弹出1。
问:获取的json的如何进行处理,response 只显示对象。
10 回答11.7k 阅读
2 回答3.2k 阅读✓ 已解决
4 回答4.6k 阅读✓ 已解决
4 回答2.1k 阅读✓ 已解决
4 回答2.2k 阅读✓ 已解决
3 回答1.2k 阅读✓ 已解决
3 回答5k 阅读
官方有比较详细的对
response
的介绍,https://github.com/vuejs/vue-...你的问题我不太明白,猜测应该是如何获取响应的
data
吧,取response.body
就行。