"http-get请求": {
"prefix": "httpget",
"body": [
"this.\\$http({",
"url: this.\\$http.adornUrl(''),",
"method: 'get',",
"params: this.\\$http.adornParams({})",
"}).then(({data}) => {",
"})"
],
"description": "httpGET请求"
},
"http-post请求": {
"prefix": "httppost",
"body": [
"this.\\$http({",
"url:this.\\$http.adornUrl(''),",
"method: 'post',",
"data: this.\\$http.adornData(data, false)",
"}).then(({ data }) => { });"
],
"description": " httpPOST请求"
}
快捷键生成后
this.$http({
url
: this.$http
.adornUrl(''),
method
: 'get',
params
: this.$http
.adornParams({})
}).then(({data
}) => {
})
this.$http({
url
:this.$http
.adornUrl(''),
method
: 'post',
data
: this.$http
.adornData(data
, false)
}).then(({ data
}) => { });
转载请注明原文地址:https://ipadbbs.8miu.com/read-44534.html