File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 11node_modules /*
2+ index.d.ts
Original file line number Diff line number Diff line change 3535 "semi-spacing": 0,
3636 "no-multi-spaces": 0,
3737 "eqeqeq": 0,
38- "no-mixed-requires": 0,
38+ "no-mixed-requires": 0
3939 },
4040 "env": {
4141 "node": true
Original file line number Diff line number Diff line change 99
1010sftp-config.json
1111yarn.lock
12+ package-lock.json
1213
1314coverage /
1415node_modules /
Original file line number Diff line number Diff line change 1+ // Definitions by: Carlos Ballesteros Velasco <https://github.com/soywiz>
2+ // Leon Yu <https://github.com/leonyu>
3+ // BendingBender <https://github.com/BendingBender>
4+ // Maple Miao <https://github.com/mapleeit>
5+
6+ /// <reference types="node" />
7+ import * as stream from 'stream' ;
8+ import * as http from 'http' ;
9+
10+ export = FormData ;
11+
12+ declare class FormData extends stream . Readable {
13+ append ( key : string , value : any , options ?: FormData . AppendOptions | string ) : void ;
14+ getHeaders ( ) : FormData . Headers ;
15+ submit (
16+ params : string | FormData . SubmitOptions ,
17+ callback ?: ( error : Error | undefined , response : http . IncomingMessage ) => void
18+ ) : http . ClientRequest ;
19+ getBuffer ( ) : Buffer ;
20+ getBoundary ( ) : string ;
21+ getLength ( callback : ( err : Error | undefined , length : number ) => void ) : void ;
22+ getLengthSync ( ) : number ;
23+ hasKnownLength ( ) : boolean ;
24+ }
25+
26+ declare namespace FormData {
27+ interface Headers {
28+ [ key : string ] : any ;
29+ }
30+
31+ interface AppendOptions {
32+ header ?: string | Headers ;
33+ knownLength ?: number ;
34+ filename ?: string ;
35+ filepath ?: string ;
36+ contentType ?: string ;
37+ }
38+
39+ interface SubmitOptions extends http . RequestOptions {
40+ protocol ?: 'https:' | 'http:' ;
41+ }
42+ }
Original file line number Diff line number Diff line change 99 },
1010 "main" : " ./lib/form_data" ,
1111 "browser" : " ./lib/browser" ,
12+ "typings" : " ./index.d.ts" ,
1213 "scripts" : {
1314 "pretest" : " rimraf coverage test/tmp" ,
1415 "test" : " istanbul cover test/run.js" ,
3738 "node" : " >= 0.12"
3839 },
3940 "dependencies" : {
41+ "@types/node" : " ^12.0.8" ,
4042 "asynckit" : " ^0.4.0" ,
4143 "combined-stream" : " ^1.0.6" ,
4244 "mime-types" : " ^2.1.12"
5961 "pre-commit" : " ^1.1.3" ,
6062 "request" : " 2.76.0" ,
6163 "rimraf" : " ^2.5.4" ,
62- "tape" : " ^4.6.2"
64+ "tape" : " ^4.6.2" ,
65+ "typescript" : " ^3.5.2"
6366 },
6467 "license" : " MIT"
6568}
You can’t perform that action at this time.
0 commit comments