doc: include ESM import for HTTP
PR-URL: https://github.com/nodejs/node/pull/53165 Reviewed-By: Matteo Collina <matteo.collina@gmail.com> Reviewed-By: Paolo Insogna <paolo@cowtech.it> Reviewed-By: Marco Ippolito <marcoippolito54@gmail.com> Reviewed-By: Vinícius Lourenço Claro Cardoso <contact@viniciusl.com.br>
This commit is contained in:
parent
bb8d2936ab
commit
78485280ca
@ -6,7 +6,8 @@
|
||||
|
||||
<!-- source_link=lib/http.js -->
|
||||
|
||||
To use the HTTP server and client one must `require('node:http')`.
|
||||
This module, containing both a client and server, can be imported via
|
||||
`require('node:http')` (CommonJS) or `import * as http from 'node:http'` (ES module).
|
||||
|
||||
The HTTP interfaces in Node.js are designed to support many features
|
||||
of the protocol which have been traditionally difficult to use.
|
||||
|
Loading…
x
Reference in New Issue
Block a user