mirror of
https://github.com/zhigang1992/DefinitelyTyped.git
synced 2026-05-13 12:37:16 +08:00
Merge pull request #17283 from newraina/fix-append-param
fix fetch.io append param
This commit is contained in:
@@ -57,3 +57,8 @@ request
|
||||
.post('')
|
||||
.send({})
|
||||
.json();
|
||||
|
||||
request
|
||||
.post('')
|
||||
.append('key', 'value')
|
||||
.append({key: 'value'});
|
||||
|
||||
6
types/fetch.io/index.d.ts
vendored
6
types/fetch.io/index.d.ts
vendored
@@ -1,4 +1,4 @@
|
||||
// Type definitions for fetch.io 3.1
|
||||
// Type definitions for fetch.io 4.0
|
||||
// Project: https://github.com/haoxins/fetch.io
|
||||
// Definitions by: newraina <https://github.com/newraina>
|
||||
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
|
||||
@@ -95,7 +95,9 @@ export class Request {
|
||||
/**
|
||||
* ppend formData
|
||||
*/
|
||||
append(key: string, value: string): this;
|
||||
append(key: string, value: any): this;
|
||||
|
||||
append(object: {[key: string]: any}): this;
|
||||
|
||||
/**
|
||||
* Get Response directly
|
||||
|
||||
Reference in New Issue
Block a user