-
Notifications
You must be signed in to change notification settings - Fork 682
Developer Notes
Current status (2017-Aug-04): http2, behind the flag --expose-http2, is expected to be released in Node 8.4 at the earliest.
When http2 is introduced in the codebase, one will need to use Node built from nodejs/node:master or nodejs/http2:initial-pr.
Until http2 is released in Node, for development purposes it might be useful to build Node with http2 exposed by default. To do so, simply search for bool config_expose_http2 = false; in src/node.cc and set the value to true.
A lot of command-line interactions with the codebase should be done through gulp tasks. Here's a list of what can be done:
-
gulp compiletranspilessrc. -
gulp test.compiletranspilessrcandtest. -
gulp testrunsgulp test.compile, and then runs all tests. -
gulp test.single --file $FILEtranspilessrcand$FILE, and runs only the transpiled$FILE. (See also: #5) -
gulp cleandeletes transpiled code. -
gulp lintlintssrcandtest.
We are not required to support to Node <6, the earliest Node version to which http2 may be back-ported. For this reason we should strongly consider using es6 as our target transpiliation language.
async/await should not be used in src/ due to performance considerations (as far as I know). It should be OK to use them in tests; Mocha supports Promises out-of-the-box.