delete(url:string, request?: Request): Response
Parameter | Type | Description |
url | string | URL string. |
request | Optional; request object. The method and url fields in the request object will not override the method and url in the current method http.delete. |
Type | Description |
Response object. |
import http from 'pts/http';export default function () {const data = { user_id: '12345' };const req = {query: data,};const resp = http.delete('http://httpbin.org/delete', req);console.log(resp.json().args.user_id); // 12345}