Merge pull request #17891 from newraina/fix-fetch-io-type

add patch method definition for fetch.io package
This commit is contained in:
Ryan Cavanaugh
2017-07-13 14:48:22 -07:00
committed by GitHub
2 changed files with 11 additions and 2 deletions

View File

@@ -23,6 +23,10 @@ request
.put('')
.json();
request
.patch('')
.json();
request
.config('key', 'value')
.json();

View File

@@ -1,4 +1,4 @@
// Type definitions for fetch.io 4.0
// Type definitions for fetch.io 4.1
// Project: https://github.com/haoxins/fetch.io
// Definitions by: newraina <https://github.com/newraina>
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
@@ -63,6 +63,11 @@ export class Request {
*/
put: (url: TUrl) => this;
/**
* HTTP patch method
*/
patch: (url: TUrl) => this;
/**
* Set Options
*/
@@ -93,7 +98,7 @@ export class Request {
send(data: {[key: string]: any}): this;
/**
* ppend formData
* append formData
*/
append(key: string, value: any): this;