OwnageIsMagic
ea2dc4dc28
Node 9.3 ( #22593 )
...
* SignalsListener signal name
https://github.com/nodejs/node/pull/15606
* created Node 8 folder
* Create tsconfig.json
* Create tslint.json
* Create node-tests.ts
* Node 9
* update node header
* Tabs to spaces
* copy inspector.d.ts to v8 folder
* correct path mapping for v8
* disable no-declare-current-package for v8 module
* Correct version to 9.3.x
Add writableHighWaterMark/readableHighWaterMark to WriteStream/ReadStream
fixed setUncaughtExceptionCaptureCallback()
Add module.builtinModules
change os.EOL to const
add writableHighWaterMark to Duplex
writableHighWaterMark and readableHighWaterMark are readonly
* fs.realpathSync.native and fs.realpath.native
* fs.realpath.native tests
2018-01-08 07:54:44 -08:00
Klaus Meinhardt
46afc73cfb
node: add module.paths ( #22578 )
2018-01-04 09:25:08 -08:00
Olaf Tomalka
abb6cbad16
Fix Node's path.format() requiring all options ( #22525 )
...
* Fix Node's path.format() requiring all options
The bug manifested during use of path.win32 and path.posix submodules.
Both functions required all of the options to exist which is not
the case as some override others.
Further research indicated that previous Node versions were also
susceptible, up to v4.
I've used the Typescript's Partial<> type which makes all properties
optional, allowing for easier maintenance and readabillity at the cost
of now requiring Typescript 2.1, which I believe is a good trade-off.
* Revert the decision to use TS 2.1 in @types/node
Updating Typescript version would require to update
all other types that rely on Node, which may be quite a lot.
Fixing a bug is not a big enough reason to add new version to all
of those packages.
2018-01-03 14:44:18 -08:00
Flarna
d9f51eae65
[node] improve typing of query.parse() ( #22171 )
...
* tabs to spaces
* [node] improve typing of query.parse()
* Update according to review:
- Better naming UrlParsedQuery => UrlWithParsedQuery, UrlStringQuery => UrlWithStringQuery
- replace Url type by UrlWithParsedQuery | UrlWithStringQuery
* Re-introduce url.Url as it is used by several other modules.
2018-01-03 11:44:10 -08:00
Mine Starks
96f8777eb5
Merge pull request #22037 from jkomyno/master
...
node: added perf_hooks module definition
2017-12-13 09:50:30 -08:00
Mine Starks
fa0b616334
Merge pull request #20561 from grantila/master
...
[node] [crypto] Added missing crypto update types
2017-12-13 09:49:47 -08:00
Gustaf Räntilä
784a62737e
Added zlib stream methods/properties
2017-12-13 13:57:49 +01:00
Gustaf Räntilä
21f749d3f3
Merge remote-tracking branch 'upstream/master'
2017-12-13 12:54:10 +01:00
jkomyno
151f13c920
[node.perf_hooks] Various fixes, added PerformanceObserver and constants
2017-12-13 00:42:34 +01:00
Mine Starks
736ebf768c
Merge pull request #22010 from GrabCAD/master
...
Add types for Error.prepareStackTrace()
2017-12-11 09:14:14 -08:00
jkomyno
8867eb032a
node: added perf_hooks module definition
2017-12-07 21:15:14 +01:00
Howard Mak
4950326dd4
PR feedback: Add test for tighter CallSite signatures
2017-12-07 12:56:37 -05:00
Bowden Kelly
f076ad2c79
Merge pull request #21994 from ctaggart/rm-node-_debugger
...
remove removed legacy Node _debugger API
2017-12-06 15:56:55 -08:00
Bowden Kelly
4dd2928253
Merge pull request #21937 from ariaviran/node4_buffer_alloc
...
[node] Add Buffer.alloc methods to node v4
2017-12-06 10:58:53 -08:00
Cameron Taggart
2871b1c240
remove removed legacy Node _debugger API
2017-12-05 21:06:38 -03:00
Howard Mak
a30bc16f3c
Tighten signature for CallSite.getTypeName()
2017-12-05 14:54:29 -05:00
Howard Mak
658b8af522
Rename NodeJS.StackFrame -> CallSite to match documentation
2017-12-05 14:33:37 -05:00
Oliver Joseph Ash
6ad156cd17
Node: use bracket notation for index signature lookup for TS 2.1
...
Support for index signature properties via dot notation was only added in TS 2.2 https://github.com/Microsoft/TypeScript/wiki/What%27s-new-in-TypeScript#dotted-property-for-types-with-string-index-signatures
2017-12-05 12:24:06 +00:00
Howard Mak
e0ba98cf88
Add signature for Error.prepareStackTrace() as per https://github.com/v8/v8/wiki/Stack%20Trace%20API
2017-12-05 00:24:40 -05:00
Ari Aviran
dccfda5de4
[node] Add Buffer.alloc methods to node v4
...
Add `Buffer.alloc`, `Buffer.allocUnsafe` and `Buffer.allocUnsafeSlow`
class methods that were backported to node v4 (starting with v4.5).
In addition add tests to all node versions for these class methods and
fix tslint configuration to pass the tests
2017-12-04 12:02:43 +02:00
Piotr Roszatycki
e36486c4e8
padLeft/padRight are defined in es2017.string lib already
2017-11-21 11:23:55 +01:00
Piotr Roszatycki
ff4b1f0af7
String object has additional ES2017 and ESNEXT methods
2017-11-17 13:51:19 +01:00
Kevin Greene
c4d7629e1b
Merge remote-tracking branch 'upstream/master' into node-client
2017-11-13 16:06:34 -08:00
Oliver Joseph Ash
a8e88654be
Node: path.format input properties are optional ( #21003 )
...
* Node: `path.format` input properties are optional
If `base` does not exist, `name` and `ext` will be used to compute it.
http://devdocs.io/node/path#path_path_format_pathobject
* Node: `FormatInputPathObject`: all properties are optional
* Node: add myself as author
* Avoid usage of `Partial`
2017-11-10 07:37:12 -08:00
Andy
9413f9cb41
node types don't really require TypeScript@2.2 ( #21283 )
2017-11-06 11:28:30 -08:00
Teppei Sato
a68863ebbd
node: improve util.promisify ( #21253 )
2017-11-06 07:03:48 -08:00
Kevin Greene
d17893c89b
Add specific properties to iIncomingHttpHeaders
2017-10-27 12:30:59 -07:00
Kevin Greene
293dc4c62a
Merge branch 'master' into node-client
2017-10-27 10:28:29 -07:00
Kevin Greene
6d2a1ad814
[node] Fix linting errors in node v8
2017-10-27 10:09:18 -07:00
Kevin Greene
d1fe542d52
Account for 'set-cookie' header in Node v8 types
2017-10-27 10:05:05 -07:00
Jinwoo Lee
b15672e837
Node http2: Fix types of statCheck() and getTrailers() ( #20729 )
...
The `headers` parameter of statCheck() and the `trailers` parameter of
getTrailers() must be OutgoingHttpHeaders, not IncomingHttpHeaders, because they
are to be updated by statCheck()/getTrailers() before being sent to the opposite
endpoint.
2017-10-23 14:58:48 -07:00
Flarna
eba2b89b3c
[node] Some fixes for net and https ( #20662 )
...
Sync Lookup function type in net, tls and dgram.
2017-10-23 13:17:14 -07:00
Jinwoo Lee
e86a56d0cc
Node http2: statCheck() may also return false. ( #20692 )
...
* Node http2: statCheck() may also return `false`.
https://nodejs.org/dist/latest-v8.x/docs/api/http2.html#http2_http2stream_respondwithfile_path_headers_options
says:
The options.statCheck function may also be used to cancel the send operation by
returning false
Related node code:
- https://github.com/nodejs/node/blob/master/lib/internal/http2/core.js#L1621
- https://github.com/nodejs/node/blob/master/lib/internal/http2/core.js#L1671
* add tests for returning false from statCheck()
* change `void|false` to `void|boolean`
* fix lint error
2017-10-19 10:22:12 -07:00
Oliver Joseph Ash
0960f82a0b
Correct type of Node url.query ( #20650 )
...
* Correct type of Node url.query
https://nodejs.org/api/url.html#url_urlobject_query
* Add null
* Node url.query: query value as array of strings
* Node: narrow query type to fix tests
2017-10-18 08:56:47 -07:00
Jinwoo Lee
63605aa515
Node: respondWithFile()'s options can have onError. ( #20659 )
...
* respondWithFile()'s `options` can have onError.
See the Node document:
https://nodejs.org/dist/latest-v8.x/docs/api/http2.html#http2_http2stream_respondwithfile_path_headers_options
And also the code:
https://github.com/nodejs/node/blob/master/lib/internal/http2/core.js#L1698
* update test
2017-10-18 08:54:49 -07:00
Jeff Kenney
43a2660602
Fix node url and http/https request types ( #18766 )
...
* [node] url.format can take a string
* [node] http.request / https.request can take a string
* [node] reorder Url properties to match ordering in docs
* [node] DRY out the Url and UrlObject types
* [node] backport split Url / UrlObject types to v0 and v4
* remove 'any' union for UrlObject.query type
2017-10-17 12:00:46 -07:00
Alessandro Vergani
d518490227
Add O_DSYNC flag ( #20638 )
2017-10-17 09:17:47 -07:00
Alessandro Vergani
52f686b9db
Add lookup to dgram SocketOptions ( #20636 )
2017-10-17 09:16:06 -07:00
Jinwoo Lee
fb93c75e47
Fix type of createPushResponse() in node http2. ( #20510 )
...
* Fix type of createPushResponse() in node http2.
From https://github.com/nodejs/node/blob/master/lib/internal/http2/compat.js#L628 :
`callback` is required to be a function. And its second argument is an `Http2ServerResponse`.
* `err` is nullable.
* delete redundant tests that have partial arguments
2017-10-17 08:35:55 -07:00
Alessandro Vergani
0905b3d2f9
Add copyFile to node file system ( #20185 )
2017-10-17 08:00:05 -07:00
Piotr Roszatycki
8ef0c39ccf
node: process.stdin is a stream.Readable and process.stdout is a stream.Writable ( #20493 )
...
* Readable.wrap returns this
* Add missing properties to interface ReadableStream and WritableStream; change interfaces in fs, dgram and net into classes
* Move all additional properties from ReadableStream interface to ReadStream interface (and Write...)
* hexo-fs should re-export classes from 'fs'
* process.stdin._destroy is a function
2017-10-17 07:44:21 -07:00
Jarrad Whitaker
d7f5d8fa90
@types/node: Asynchooks promiseResolve and AsyncResource ( #20540 )
...
* add promiseResolve hook
* add AsyncResource
* AsyncResource jsdoc fixes
* test remaining AsyncResource methods
2017-10-16 13:42:29 -07:00
Piotr Roszatycki
173d1d4e9e
node: dgram buffer size options and methods for Node 8.7.0 ( #20535 )
...
* dgram buffer size options and methods
* Verify type returned by dgram.*BufferSize methods
2017-10-16 13:40:56 -07:00
kazuyamamoto
ea8b7af8c6
[node] Add tls.getCiphers() and tls.DEFAULT_ECDH_CURVE ( #20482 )
...
https://nodejs.org/api/tls.html#tls_tls_getciphers
https://nodejs.org/api/tls.html#tls_tls_default_ecdh_curve
2017-10-16 13:16:08 -07:00
Robert K. Bell
547c7fd610
[types/node] Add final option to Stream WritableOptions ( #20477 )
...
* fix: add `final` option for WritableStreams
* fix: use more accurate type for `final()`
* typo: whitespace
* test: add `final` option
as documented here:
https://nodejs.org/docs/latest/api/stream.html#stream_constructor_new_stream_writable_options
* fix: cb is mandatory, error is optional
2017-10-16 13:15:22 -07:00
Flarna
2466ddbcff
[node] Add Buffer.poolSize() and correct Buffer.byteLength() ( #20419 )
...
* [node] Add Buffer.poolSize
* [node] Allow more types for Buffer.byteLength()
* fix lint issue
2017-10-16 11:18:42 -07:00
Alessandro Vergani
0e7cad3271
Add setMulticastInterface to node dgram ( #20186 )
2017-10-16 10:39:48 -07:00
Martijn Schrage
55a284355b
Add missing method readline.emitKeypressEvents to package node ( #19733 )
2017-10-16 08:47:24 -07:00
Rogier Schouten
ca3ec2cfe8
fix Node net.createConnection() and Socket#connect() signatures. ( #19456 )
...
* fix net.createConnection() and Socket#connect() signatures.
* fix lint errors.
* Fix review comments.
2017-10-16 08:26:29 -07:00
Gustaf Räntilä
4bed8394f2
[node] [crypto] Added missing crypto update types
...
* Added DataView as type of crypto update functions
2017-10-13 14:23:39 +02:00