【发布时间】:2020-10-04 14:23:05
【问题描述】:
我已将愿望清单项目存储在 cookie 中, 但是在隐身标签中,没有cookie,因此无法获取数据。
我想出了这个扩展的东西,它增加了 3 个端点 https://github.com/mediamanDE/magento-module-wishlist-api
为用户获取愿望清单。
例子:
$ curl -X GET http://magento.example.com/rest/V1/wishlist --header "Authorization: Bearer pbhercbtk6dd3eatf1pyx8jj45avjluu"
如何在 Vue 中发起或调用这个请求?
【问题讨论】:
-
与
fetch()?axios? -
我也是这么想的,其实我想调用它的rest api
-
响应是 JSON 吗?
-
@Ifaruki 见raw.githubusercontent.com/mediamanDE/…
-
是的,json响应
标签: vue.js vuejs2 vue-component vuetify.js