diff --git a/build.js b/build.js index bb7e6fa68937..c3dec7fc4c0d 100755 --- a/build.js +++ b/build.js @@ -6,6 +6,7 @@ const fs = require('fs'); const gracefulFs = require('graceful-fs'); + // This is needed at least on Windows to prevent the `EMFILE: too many open files` error // https://github.com/isaacs/node-graceful-fs#global-patching gracefulFs.gracefulify(fs); @@ -268,7 +269,7 @@ function withPreserveLocale(preserveLocale) { } // This function builds the static/css folder for all the Sass files. -function buildCSS() { +async function buildCSS() { console.log('[sass] static/css started'); const labelForBuild = '[sass] static/css finished'; console.time(labelForBuild); @@ -277,88 +278,70 @@ function buildCSS() { const dest = path.join(__dirname, 'build/static/css/styles.css'); const sassOpts = { - file: src, - outFile: dest, outputStyle: process.env.NODE_ENV !== 'development' ? 'compressed' : 'expanded' }; - gracefulFs.mkdir( - path.join(__dirname, 'build/static/css'), - { recursive: true }, - (err) => { - if (err) { - throw err; - } - - sass.render(sassOpts, (error, result) => { - if (error) { - throw error; - } + const graceFulFsPromise = gracefulFs.promises; - postcss([autoprefixer]) - .process(result.css, { from: src }) - .then((res) => { - res.warnings().forEach((warn) => { - console.warn(warn.toString()); - }); + await graceFulFsPromise.mkdir(path.join(__dirname, 'build/static/css'), { + recursive: true + }); - gracefulFs.writeFile(dest, res.css, (err) => { - if (err) { - throw err; - } + const result = await sass.compileAsync(src, sassOpts); - console.timeEnd(labelForBuild); - }); - }); + postcss([autoprefixer]) + .process(result.css, { from: src }) + .then(async (res) => { + res.warnings().forEach((warn) => { + console.warn(warn.toString()); }); - } - ); + + await graceFulFsPromise.writeFile(dest, res.css); + console.timeEnd(labelForBuild); + }); } // This function copies the rest of the static assets to their subfolder in the // build directory. -function copyStatic() { +async function copyStatic() { console.log('[ncp] build/static started'); const labelForBuild = '[ncp] build/static finished'; console.time(labelForBuild); - gracefulFs.mkdir( + + const graceFulFsPromise = gracefulFs.promises; + + await graceFulFsPromise.mkdir(path.join(__dirname, 'build/static'), { + recursive: true + }); + + ncp( + path.join(__dirname, 'static'), path.join(__dirname, 'build/static'), - { recursive: true }, - (err) => { - if (err) { - throw err; + (error) => { + if (error) { + return console.error(error); } ncp( - path.join(__dirname, 'static'), - path.join(__dirname, 'build/static'), + path.join(__dirname, 'node_modules/jquery/dist/jquery.min.js'), + path.join(__dirname, 'build/static/js/jquery.min.js'), (error) => { if (error) { return console.error(error); } ncp( - path.join(__dirname, 'node_modules/jquery/dist/jquery.min.js'), - path.join(__dirname, 'build/static/js/jquery.min.js'), + path.join( + __dirname, + 'node_modules/jquery.fancytable/dist/fancyTable.min.js' + ), + path.join(__dirname, 'build/static/js/fancyTable.min.js'), (error) => { if (error) { return console.error(error); } - - ncp( - path.join( - __dirname, - 'node_modules/jquery.fancytable/dist/fancyTable.min.js' - ), - path.join(__dirname, 'build/static/js/fancyTable.min.js'), - (error) => { - if (error) { - return console.error(error); - } - console.timeEnd(labelForBuild); - } - ); + console.timeEnd(labelForBuild); } ); } @@ -398,25 +381,24 @@ function getSource(callback) { // name. It brings together all build steps and dependencies and executes them. function fullBuild(opts) { const { selectedLocales, preserveLocale } = opts; - getSource((err, source) => { + getSource(async (err, source) => { if (err) { throw err; } - // Executes the build cycle for every locale. - gracefulFs.readdir(path.join(__dirname, 'locale'), (e, locales) => { - if (e) { - throw e; - } - const filteredLocales = locales.filter( - (file) => - junk.not(file) && - (selectedLocales ? selectedLocales.includes(file) : true) - ); - const localesData = generateLocalesData(filteredLocales); - filteredLocales.forEach((locale) => { - buildLocale(source, locale, { preserveLocale, localesData }); - }); + const graceFulFsPromise = gracefulFs.promises; + const locales = await graceFulFsPromise.readdir( + path.join(__dirname, 'locale') + ); + + const filteredLocales = locales.filter( + (file) => + junk.not(file) && + (selectedLocales ? selectedLocales.includes(file) : true) + ); + const localesData = generateLocalesData(filteredLocales); + filteredLocales.forEach((locale) => { + buildLocale(source, locale, { preserveLocale, localesData }); }); }); } diff --git a/locale/ar/download/package-manager.md b/locale/ar/download/package-manager.md index fd024f08f059..06f13e4ca464 100644 --- a/locale/ar/download/package-manager.md +++ b/locale/ar/download/package-manager.md @@ -24,7 +24,7 @@ title: تثبيت Node.js عن طريق مدير الحزم * [SmartOS و illumos](#smartos-and-illumos) * [Solus](#solus) * [Void Linux](#void-linux) -* [ويندوز](#windows) +* [Windows](#windows1) --- @@ -273,7 +273,7 @@ sudo eopkg install nodejs xbps-install -Sy nodejs ``` -## ويندوز +## ويندوز قم بتحميل [المثبت الخاص بويندوز](https://nodejs.org/ar/#home-downloadhead) مباشرة من موقع [nodejs.org](https://nodejs.org/). diff --git a/locale/en/blog/announcements/v18-release-announce.md b/locale/en/blog/announcements/v18-release-announce.md new file mode 100644 index 000000000000..9c43d0361d86 --- /dev/null +++ b/locale/en/blog/announcements/v18-release-announce.md @@ -0,0 +1,171 @@ +--- +title: Node.js 18 is now available! +date: 2022-04-19T15:45:00.000Z +status: publish +category: Announcements +slug: nodejs-18-release-announcement +layout: blog-post.hbs +author: The Node.js Project +--- + +We’re excited to announce that Node.js 18 was released today! Highlights include the update of the V8 JavaScript engine to 10.1, global fetch enabled by default, and a core test runner module. + +Initially, Node.js 18 will replace Node.js 17 as our ‘Current’ release line. As per the release schedule, Node.js 18 will be the 'Current' release for the next 6 months and then promoted to Long-term Support (LTS) in October 2022. Once promoted to long-term support the release will be designated the codename 'Hydrogen'. Node.js 18 will be supported until April 2025. + +You can read more about our release policy at https://github.com/nodejs/release. + +To download Node.js 18.0.0, visit: https://nodejs.org/en/download/current/. You can find the release post at https://nodejs.org/en/blog/release/v18.0.0, which contains the full list of commits included in this release. + +## New globally available browser-compatible APIs + +### fetch (experimental) + +In Node.js 18, an experimental global fetch API is available by default. The implementation comes from [undici](https://undici.nodejs.org/#/) and is inspired by [node-fetch](https://github.com/node-fetch/node-fetch) which was originally based upon [undici-fetch](https://github.com/Ethan-Arrowood/undici-fetch). The implementation strives to be as close to spec-compliant as possible, but some aspects would require a browser environment and are thus omitted. + +The API will remain experimental until more test coverage is added and the contributors have verified that the API implements as much of the specification as is feasible. If you are looking to get involved visit the [nodejs/undici](https://github.com/nodejs/undici) repository and look for [issues tagged with fetch](https://github.com/nodejs/undici/issues?q=is%3Aissue+is%3Aopen+label%3Afetch). + +Example usage of this API: + +```mjs +const res = await fetch('https://nodejs.org/api/documentation.json'); +if (res.ok) { + const data = await res.json(); + console.log(data); +} +``` + +Through this addition, the following globals are made available: `fetch`, `FormData`, `Headers`, `Request`, `Response`. + +It's possible to disable the API by supplying the `--no-experimental-fetch` command-line flag. + +The `fetch()` implementation in `undici` was led by Robert Nagy, Ethan Arrowood, and Matteo Collina. The implementation was added to Node.js core by Michaël Zasso in [#41811](https://github.com/nodejs/node/pull/41811). + +### Web Streams API (experimental) + +Node.js now exposes the experimental implementation of the [Web Streams API](https://developer.mozilla.org/en-US/docs/Web/API/Streams_API) on the global scope. This means the following APIs are now globally available: + +* `ReadableStream`, `ReadableStreamDefaultReader`, `ReadableStreamBYOBReader`, `ReadableStreamBYOBRequest`, `ReadableByteStreamController`, `ReadableStreamDefaultController`, `TransformStream`, `TransformStreamDefaultController`, `WritableStream`, `WritableStreamDefaultWriter`, `WritableStreamDefaultController`, `ByteLengthQueuingStrategy`, `CountQueuingStrategy`, `TextEncoderStream`, `TextDecoderStream`, `CompressionStream`, `DecompressionStream`. + +Contributed James Snell in [#39062](https://github.com/nodejs/node/pull/39062), and Antoine du Hamel in [#42225](https://github.com/nodejs/node/pull/42225). + +### Other global APIs + +Additionally, the following APIs are now exposed on the global scope: +* `Blob` - +* `BroadcastChannel` - + +Both of these APIs are also no longer experimental. + +Contributed by James Snell in [#41270](https://github.com/nodejs/node/pull/41270) and [#41271](https://github.com/nodejs/node/pull/41271). + +## Test runner module (experimental) + +The `node:test` module facilitates the creation of JavaScript tests that report results in TAP format. To access it: + +`import test from 'node:test';` + +The following is an example implementation of a parent test with two subtests: + +```js +test('top level test', async (t) => { + await t.test('subtest 1', (t) => { + assert.strictEqual(1, 1); + }); + + await t.test('subtest 2', (t) => { + assert.strictEqual(2, 2); + }); +}); +``` + +Note that the test runner module is only available using the `node:` prefix. The `node:` prefix denotes the loading of a core module. Omitting the prefix and importing `'test'` would attempt to load a userland module. + +Read more at . + +Contributed by Colin Ihrig in [#42325](https://github.com/nodejs/node/pull/42325). + +## Toolchain and Compiler Upgrades + +Node.js provides pre-built binaries for several different platforms. For each major release, the minimum toolchains are assessed and raised where appropriate. + +* Prebuilt binaries for Linux are now built on Red Hat Enterprise Linux (RHEL) 8 and are compatible with Linux distributions based on glibc 2.28 or later, for example, Debian 10, RHEL 8, Ubuntu 20.04. +* Prebuilt binaries for macOS now require macOS 10.15 or later. +* For AIX the minimum supported architecture has been raised from Power 7 to Power 8. + +Prebuilt binaries for 32-bit Windows will initially not be available due to issues building the V8 dependency in Node.js. We hope to restore 32-bit Windows binaries for Node.js 18 with a future V8 update. + +Node.js does not support running on operating systems that are no longer supported by their vendor. For operating systems where their vendor has planned to end support earlier than April 2025, such as Windows 8.1 (January 2023) and Windows Server 2012 R2 (October 2023), support for Node.js 18 will end at the earlier date. + +Full details about the supported toolchains and compilers are documented in the Node.js [BUILDING.md](https://github.com/nodejs/node/blob/v18.x/BUILDING.md#supported-platforms) file. + +The Node.js team would once again like to thank our infrastructure providers Digital Ocean, Rackspace, ARM, Cloudflare, Equinix, IBM, Intel, Joyent, Macstadium, Microsoft, and Oregon State University Open Source Lab for contributing the infrastructure for the project. We would also like to thank Red Hat for providing no-cost Red Hat subscriptions under their [Red Hat for Open Source Infrastructure](https://www.redhat.com/en/blog/extending-no-cost-red-hat-enterprise-linux-open-source-organizations) program. + +Contributed by Richard Lau ([#42292](https://github.com/nodejs/node/pull/42292), [#42604](https://github.com/nodejs/node/pull/42604), and [#42659](https://github.com/nodejs/node/pull/42659)) and Michaël Zasso ([#42105](https://github.com/nodejs/node/pull/42105) and [#42666](https://github.com/nodejs/node/pull/42666)). Cross compiler for ARMv7 upgrade contributed by Rod Vagg. + +## Build-time user-land snapshot (experimental) + +Starting from Node.js 18.0.0, users can build a Node.js binary with a custom V8 startup snapshot using the `--node-snapshot-main` flag of the configure script. For example: + +```console +$ cd /path/to/node/source + +# Specifying an entry point of the snapshot, for example, +# a UMD module like the marked markdown renderer which in +# this case should initialize the renderer and stores in +# globalThis. +$ ./configure --node-snapshot-main=marked.js + +# Build the binary +$ make node +``` + +The resulted binary can deserialize the state of the heap that was initialized by the snapshot entry point at build time, so the application in generated binary can be initialized faster: + +```js +// render.js +// globalThis.marked can be deserialized from the embedded +// snapshot so there is no need to parse and execute the +// module again, which improves startup time. +const html = globalThis.marked(process.argv[1]); +console.log(html); +``` + +The generated binary can be executed like this: + +```console +$ out/Release/node render.js test.md +``` + +As a follow-up, we are working on JS APIs for the userland snapshot ([#42617](https://github.com/nodejs/node/issues/42617)) so that the binary can be executed without an additional runtime entry point script, effectively turning it into a single-file executable containing a user application. We are also working on making the feature a run-time flag ([#38905](https://github.com/nodejs/node/pull/38905)) so that the snapshot can be generated and loaded without a compiler. + +Contributed by Joyee Cheung in [#42466](https://github.com/nodejs/node/pull/42466). + +## V8 10.1 + +The V8 engine is updated to version 10.1, which is part of Chromium 101. Compared +to the version included in Node.js 17.9.0, the following new features are included: + +* The [`findLast()` and `findLastIndex()` array methods](https://v8.dev/features/finding-in-arrays). +* Improvements to the [`Intl.Locale` API](https://v8.dev/blog/v8-release-99#intl.locale-extensions). +* The [`Intl.supportedValuesOf` function](https://v8.dev/blog/v8-release-99#intl-enumeration). +* Improved performance of [class fields and private class methods](https://v8.dev/blog/faster-class-features) (the initialization of them is now as fast as ordinary property stores). + +Contributed by Michaël Zasso in [#42657](https://github.com/nodejs/node/pull/42657). + +## Other project news + +While not new in Node.js 18, over the past months the project has continued to develop its ECMAScript modules implementation. Notable milestones include adding experimental support for [JSON Import Assertions](https://github.com/tc39/proposal-import-assertions), the unflagging of JSON modules (experimental), and experimental support for HTTPS and HTTP imports. The [Node.js Loaders team](https://github.com/nodejs/loaders) is also continuing to develop the ECMAScript Modules Loaders implementation in Node.js. + +The project is also continuing its [‘Next 10’](https://github.com/nodejs/next-10) effort. The goal of this effort is to reflect on what led to success in the first 10 years of Node.js and set the direction for success in the next 10. Several meetings have been held to discuss the next steps on the agreed [technical priorities](https://github.com/nodejs/node/blob/master/doc/contributing/technical-priorities.md). There have already been great discussions on Modern HTTP, WebAssembly, and Types. The next sessions on ECMAScript modules and Observability are planned to be part of the collaborator summit at the upcoming [OpenJS World](https://events.linuxfoundation.org/openjs-world/) conference in June. + +## Call to action! + +Try out the new Node.js 18 release! We’re always happy to hear your feedback. Testing your applications and modules with Node.js 18 helps to ensure the future compatibility of your project with the latest Node.js changes and features. + +Also of note is that Node.js 12 will go End-of-Life in April 2022, so we advise you to start planning to upgrade to Node.js 14 (LTS) or Node.js 16 (LTS). + +For the timeline of Node.js releases, check out the [Node.js Release Schedule](https://github.com/nodejs/release#release-schedule). + +## Thank you! + +We’d like to thank all of the Node.js collaborators and contributors, as this release is a sum of all their continued efforts. diff --git a/locale/en/blog/release/v18.0.0.md b/locale/en/blog/release/v18.0.0.md new file mode 100644 index 000000000000..221ffe187037 --- /dev/null +++ b/locale/en/blog/release/v18.0.0.md @@ -0,0 +1,335 @@ +--- +date: 2022-04-19T15:56:25.848Z +version: 18.0.0 +category: release +title: Node v18.0.0 (Current) +slug: node-v18-0-0 +layout: blog-post.hbs +author: Bethany Nicolle Griggs +--- + +### Notable Changes + +#### Deprecations and Removals + +* **(SEMVER-MAJOR)** **fs**: runtime deprecate string coercion in `fs.write`, `fs.writeFileSync` (Livia Medeiros) [#42607](https://github.com/nodejs/node/pull/42607) +* **(SEMVER-MAJOR)** **dns**: remove `dns.lookup` and `dnsPromises.lookup` options type coercion (Antoine du Hamel) [#41431](https://github.com/nodejs/node/pull/41431) +* **(SEMVER-MAJOR)** **process**: runtime deprecate multipleResolves (Benjamin Gruenbaum) [#41896](https://github.com/nodejs/node/pull/41896) +* **(SEMVER-MAJOR)** **stream**: remove thenable support (Robert Nagy) [#40773](https://github.com/nodejs/node/pull/40773) +* **(SEMVER-MAJOR)** **tls**: move tls.parseCertString to end-of-life (Tobias Nießen) [#41479](https://github.com/nodejs/node/pull/41479) + +#### fetch (experimental) + +An experimental fetch API is available on the global scope by default. The implementation is based upon [undici](https://undici.nodejs.org/#/), an HTTP/1.1 client written for Node.js by contributors to the project. + +```mjs +const res = await fetch('https://nodejs.org/api/documentation.json'); +if (res.ok) { + const data = await res.json(); + console.log(data); +} +``` + +Through this addition, the following globals are made available: `fetch`, `FormData`, `Headers`, `Request`, `Response`. + +Disable this API with the `--no-experimental-fetch` command-line flag. + +Contributed by Michaël Zasso in [#41811](https://github.com/nodejs/node/pull/41811). + +#### HTTP Timeouts + +`server.headersTimeout` which limits the amount of time the parser will wait to receive the complete HTTP headers is now set to `60000` (60 seconds) by default. + +`server.requestTimeout` which sets the timeout value in milliseconds for receiving the entire request from the client is now set to `300000` (5 minutes) by default. + +If these timeouts expire, the server responds with status 408 without forwarding the request to the request listener and then closes the connection. + +Both timeouts must be set to a non-zero value to protect against potential Denial-of-Service attacks in case the server is deployed without a reverse proxy in front. + +Contributed by Paolo Insogna in [#41263](https://github.com/nodejs/node/pull/41263). + +#### Test Runner module (experimental) + +The `node:test` module facilitates the creation of JavaScript tests that report results in TAP format. To access it: + +`import test from 'node:test';` + +This module is only available under the `node:` scheme. + +The following is an example implementation of a parent test with two subtests: + +```js +test('top level test', async (t) => { + await t.test('subtest 1', (t) => { + assert.strictEqual(1, 1); + }); + + await t.test('subtest 2', (t) => { + assert.strictEqual(2, 2); + }); +}); +``` + +Read more in . + +Contributed by Colin Ihrig in [#42325](https://github.com/nodejs/node/pull/42325). + +#### Toolchain and Compiler Upgrades + +* Prebuilt binaries for Linux are now built on Red Hat Enterprise Linux (RHEL) 8 and are compatible with Linux distributions based on glibc 2.28 or later, for example, Debian 10, RHEL 8, Ubuntu 20.04. +* Prebuilt binaries for macOS now require macOS 10.15 or later. +* For AIX the minimum supported architecture has been raised from Power 7 to Power 8. + +Prebuilt binaries for 32-bit Windows will initially not be available due to issues building the V8 dependency in Node.js. We hope to restore 32-bit Windows binaries for Node.js 18 with a future V8 update. + +Node.js does not support running on operating systems that are no longer supported by their vendor. For operating systems where their vendor has planned to end support earlier than April 2025, such as Windows 8.1 (January 2023) and Windows Server 2012 R2 (October 2023), support for Node.js 18 will end at the earlier date. + +Full details about the supported toolchains and compilers are documented in the Node.js [BUILDING.md](https://github.com/nodejs/node/blob/v18.x/BUILDING.md#supported-platforms) file. + +Contributed by Richard Lau in [#42292](https://github.com/nodejs/node/pull/42292), [#42604](https://github.com/nodejs/node/pull/42604) and [#42659](https://github.com/nodejs/node/pull/42659),and Michaël Zasso in [#42105](https://github.com/nodejs/node/pull/42105) and [#42666](https://github.com/nodejs/node/pull/42666). + +#### V8 10.1 + +The V8 engine is updated to version 10.1, which is part of Chromium 101. Compared to the version included in Node.js 17.9.0, the following new features are included: + +* The [`findLast` and `findLastIndex` array methods](https://v8.dev/features/finding-in-arrays). +* Improvements to the [`Intl.Locale` API](https://v8.dev/blog/v8-release-99#intl.locale-extensions). +* The [`Intl.supportedValuesOf` function](https://v8.dev/blog/v8-release-99#intl-enumeration). +* Improved performance of [class fields](https://bugs.chromium.org/p/v8/issues/detail?id=9888) and [private class methods](https://bugs.chromium.org/p/v8/issues/detail?id=10793) (the initialization of them is now as fast as ordinary property stores). + +The data format returned by the serialization API (`v8.serialize(value)`) has changed, and cannot be deserialized by earlier versions of Node.js. On the other hand, it is still possible to deserialize the previous format, as the API is backwards-compatible. + +Contributed by Michaël Zasso in . + +#### Web Streams API (experimental) + +Node.js now exposes the experimental implementation of the [Web Streams API](https://developer.mozilla.org/en-US/docs/Web/API/Streams_API) on the global scope. This means the following APIs are now globally available: + +* `ReadableStream`, `ReadableStreamDefaultReader`, `ReadableStreamBYOBReader`, `ReadableStreamBYOBRequest`, `ReadableByteStreamController`, `ReadableStreamDefaultController`, `TransformStream`, `TransformStreamDefaultController`, `WritableStream`, `WritableStreamDefaultWriter`, `WritableStreamDefaultController`, `ByteLengthQueuingStrategy`, `CountQueuingStrategy`, `TextEncoderStream`, `TextDecoderStream`, `CompressionStream`, `DecompressionStream`. + +Contributed James Snell in , and Antoine du Hamel in . + +#### Other Notable Changes + +* **(SEMVER-MAJOR)** **buffer**: expose Blob as a global (James M Snell) [#41270](https://github.com/nodejs/node/pull/41270) +* **(SEMVER-MAJOR)** **child\_process**: improve argument validation (Rich Trott) [#41305](https://github.com/nodejs/node/pull/41305) +* **doc**: add RafaelGSS to collaborators (RafaelGSS) [#42718](https://github.com/nodejs/node/pull/42718) +* **(SEMVER-MAJOR)** **http**: make TCP noDelay enabled by default (Paolo Insogna) [#42163](https://github.com/nodejs/node/pull/42163) +* **(SEMVER-MAJOR)** **net**: make `server.address()` return an integer for `family` (Antoine du Hamel) [#41431](https://github.com/nodejs/node/pull/41431) +* **(SEMVER-MAJOR)** **worker**: expose BroadcastChannel as a global (James M Snell) [#41271](https://github.com/nodejs/node/pull/41271) +* **(SEMVER-MAJOR)** **worker**: graduate BroadcastChannel to supported (James M Snell) [#41271](https://github.com/nodejs/node/pull/41271) + +### Semver-Major Commits + +* \[[`dab8ab2837`](https://github.com/nodejs/node/commit/dab8ab2837)] - **(SEMVER-MAJOR)** **assert,util**: compare RegExp.lastIndex while using deep equal checks (Ruben Bridgewater) [#41020](https://github.com/nodejs/node/pull/41020) +* \[[`cff14bcaef`](https://github.com/nodejs/node/commit/cff14bcaef)] - **(SEMVER-MAJOR)** **buffer**: refactor `byteLength` to remove outdated optimizations (Rongjian Zhang) [#38545](https://github.com/nodejs/node/pull/38545) +* \[[`cea76dbf33`](https://github.com/nodejs/node/commit/cea76dbf33)] - **(SEMVER-MAJOR)** **buffer**: expose Blob as a global (James M Snell) [#41270](https://github.com/nodejs/node/pull/41270) +* \[[`99c18f4786`](https://github.com/nodejs/node/commit/99c18f4786)] - **(SEMVER-MAJOR)** **buffer**: graduate Blob from experimental (James M Snell) [#41270](https://github.com/nodejs/node/pull/41270) +* \[[`35d72bf4ec`](https://github.com/nodejs/node/commit/35d72bf4ec)] - **(SEMVER-MAJOR)** **build**: make x86 Windows support temporarily experimental (Michaël Zasso) [#42666](https://github.com/nodejs/node/pull/42666) +* \[[`1134d8faf8`](https://github.com/nodejs/node/commit/1134d8faf8)] - **(SEMVER-MAJOR)** **build**: bump macOS deployment target to 10.15 (Richard Lau) [#42292](https://github.com/nodejs/node/pull/42292) +* \[[`27eb91d378`](https://github.com/nodejs/node/commit/27eb91d378)] - **(SEMVER-MAJOR)** **build**: downgrade Windows 8.1 and server 2012 R2 to experimental (Michaël Zasso) [#42105](https://github.com/nodejs/node/pull/42105) +* \[[`26c973d4b3`](https://github.com/nodejs/node/commit/26c973d4b3)] - **(SEMVER-MAJOR)** **child\_process**: improve argument validation (Rich Trott) [#41305](https://github.com/nodejs/node/pull/41305) +* \[[`38007df999`](https://github.com/nodejs/node/commit/38007df999)] - **(SEMVER-MAJOR)** **cluster**: make `kill` to be just `process.kill` (Bar Admoni) [#34312](https://github.com/nodejs/node/pull/34312) +* \[[`aed18dfe59`](https://github.com/nodejs/node/commit/aed18dfe59)] - **(SEMVER-MAJOR)** **crypto**: cleanup validation (Mohammed Keyvanzadeh) [#39841](https://github.com/nodejs/node/pull/39841) +* \[[`e1fb6ae02f`](https://github.com/nodejs/node/commit/e1fb6ae02f)] - **(SEMVER-MAJOR)** **crypto**: prettify othername in PrintGeneralName (Tobias Nießen) [#42123](https://github.com/nodejs/node/pull/42123) +* \[[`36fb79030e`](https://github.com/nodejs/node/commit/36fb79030e)] - **(SEMVER-MAJOR)** **crypto**: fix X509Certificate toLegacyObject (Tobias Nießen) [#42124](https://github.com/nodejs/node/pull/42124) +* \[[`563b2ed000`](https://github.com/nodejs/node/commit/563b2ed000)] - **(SEMVER-MAJOR)** **crypto**: use RFC2253 format in PrintGeneralName (Tobias Nießen) [#42002](https://github.com/nodejs/node/pull/42002) +* \[[`18365d8ee6`](https://github.com/nodejs/node/commit/18365d8ee6)] - **(SEMVER-MAJOR)** **crypto**: change default check(Host|Email) behavior (Tobias Nießen) [#41600](https://github.com/nodejs/node/pull/41600) +* \[[`58f3fdcccd`](https://github.com/nodejs/node/commit/58f3fdcccd)] - **(SEMVER-MAJOR)** **deps**: V8: cherry-pick semver-major commits from 10.2 (Michaël Zasso) [#42657](https://github.com/nodejs/node/pull/42657) +* \[[`fd4f80ce54`](https://github.com/nodejs/node/commit/fd4f80ce54)] - **(SEMVER-MAJOR)** **deps**: update V8 to 10.1.124.6 (Michaël Zasso) [#42657](https://github.com/nodejs/node/pull/42657) +* \[[`974ab4060f`](https://github.com/nodejs/node/commit/974ab4060f)] - **(SEMVER-MAJOR)** **deps**: update V8 to 9.8.177.9 (Michaël Zasso) [#41610](https://github.com/nodejs/node/pull/41610) +* \[[`270253c4e2`](https://github.com/nodejs/node/commit/270253c4e2)] - **(SEMVER-MAJOR)** **deps**: update V8 to 9.7.106.18 (Michaël Zasso) [#40907](https://github.com/nodejs/node/pull/40907) +* \[[`08773e3c04`](https://github.com/nodejs/node/commit/08773e3c04)] - **(SEMVER-MAJOR)** **dns**: remove `dns.lookup` and `dnsPromises.lookup` options type coercion (Antoine du Hamel) [#41431](https://github.com/nodejs/node/pull/41431) +* \[[`3671cc0432`](https://github.com/nodejs/node/commit/3671cc0432)] - **(SEMVER-MAJOR)** **doc**: update minimum glibc requirements for Linux (Richard Lau) [#42659](https://github.com/nodejs/node/pull/42659) +* \[[`646e057680`](https://github.com/nodejs/node/commit/646e057680)] - **(SEMVER-MAJOR)** **doc**: update AIX minimum supported arch (Richard Lau) [#42604](https://github.com/nodejs/node/pull/42604) +* \[[`0bac5478eb`](https://github.com/nodejs/node/commit/0bac5478eb)] - **(SEMVER-MAJOR)** **fs**: runtime deprecate string coercion in `fs.write`, `fs.writeFileSync` (Livia Medeiros) [#42607](https://github.com/nodejs/node/pull/42607) +* \[[`3caa2c1a00`](https://github.com/nodejs/node/commit/3caa2c1a00)] - **(SEMVER-MAJOR)** **http**: refactor headersTimeout and requestTimeout logic (Paolo Insogna) [#41263](https://github.com/nodejs/node/pull/41263) +* \[[`eacd45656a`](https://github.com/nodejs/node/commit/eacd45656a)] - **(SEMVER-MAJOR)** **http**: make TCP noDelay enabled by default (Paolo Insogna) [#42163](https://github.com/nodejs/node/pull/42163) +* \[[`4944ad0b9e`](https://github.com/nodejs/node/commit/4944ad0b9e)] - **(SEMVER-MAJOR)** **lib**: enable fetch by default (Michaël Zasso) [#41811](https://github.com/nodejs/node/pull/41811) +* \[[`8c4b8b201a`](https://github.com/nodejs/node/commit/8c4b8b201a)] - **(SEMVER-MAJOR)** **lib**: replace validator and error (Mohammed Keyvanzadeh) [#41678](https://github.com/nodejs/node/pull/41678) +* \[[`3c4ee5267a`](https://github.com/nodejs/node/commit/3c4ee5267a)] - **(SEMVER-MAJOR)** **module,repl**: support 'node:'-only core modules (Colin Ihrig) [#42325](https://github.com/nodejs/node/pull/42325) +* \[[`3a26db9697`](https://github.com/nodejs/node/commit/3a26db9697)] - **(SEMVER-MAJOR)** **net**: make `server.address()` return an integer for `family` (Antoine du Hamel) [#41431](https://github.com/nodejs/node/pull/41431) +* \[[`e6a7300a10`](https://github.com/nodejs/node/commit/e6a7300a10)] - **(SEMVER-MAJOR)** **process**: disallow some uses of Object.defineProperty() on process.env (Himself65) [#28006](https://github.com/nodejs/node/pull/28006) +* \[[`60b8e79599`](https://github.com/nodejs/node/commit/60b8e79599)] - **(SEMVER-MAJOR)** **process**: runtime deprecate multipleResolves (Benjamin Gruenbaum) [#41896](https://github.com/nodejs/node/pull/41896) +* \[[`d36b60e69a`](https://github.com/nodejs/node/commit/d36b60e69a)] - **(SEMVER-MAJOR)** **readline**: fix question still called after closed (Xuguang Mei) [#42464](https://github.com/nodejs/node/pull/42464) +* \[[`58e645de63`](https://github.com/nodejs/node/commit/58e645de63)] - **(SEMVER-MAJOR)** **stream**: remove thenable support (Robert Nagy) [#40773](https://github.com/nodejs/node/pull/40773) +* \[[`560cbc5849`](https://github.com/nodejs/node/commit/560cbc5849)] - **(SEMVER-MAJOR)** **stream**: expose web streams globals, remove runtime experimental warning (Antoine du Hamel) [#42225](https://github.com/nodejs/node/pull/42225) +* \[[`9fb7ac3bbd`](https://github.com/nodejs/node/commit/9fb7ac3bbd)] - **(SEMVER-MAJOR)** **stream**: need to cleanup event listeners if last stream is readable (Xuguang Mei) [#41954](https://github.com/nodejs/node/pull/41954) +* \[[`ceaa299958`](https://github.com/nodejs/node/commit/ceaa299958)] - **(SEMVER-MAJOR)** **stream**: revert revert `map` spec compliance (Benjamin Gruenbaum) [#41933](https://github.com/nodejs/node/pull/41933) +* \[[`fe7ca085a7`](https://github.com/nodejs/node/commit/fe7ca085a7)] - **(SEMVER-MAJOR)** **stream**: throw invalid arg type from End Of Stream (Jithil P Ponnan) [#41766](https://github.com/nodejs/node/pull/41766) +* \[[`48e784043d`](https://github.com/nodejs/node/commit/48e784043d)] - **(SEMVER-MAJOR)** **stream**: don't emit finish after destroy (Robert Nagy) [#40852](https://github.com/nodejs/node/pull/40852) +* \[[`f2170253b6`](https://github.com/nodejs/node/commit/f2170253b6)] - **(SEMVER-MAJOR)** **stream**: add errored and closed props (Robert Nagy) [#40696](https://github.com/nodejs/node/pull/40696) +* \[[`432d1b50e0`](https://github.com/nodejs/node/commit/432d1b50e0)] - **(SEMVER-MAJOR)** **test**: add initial test module (Colin Ihrig) [#42325](https://github.com/nodejs/node/pull/42325) +* \[[`92567283f4`](https://github.com/nodejs/node/commit/92567283f4)] - **(SEMVER-MAJOR)** **timers**: refactor internal classes to ES2015 syntax (Rabbit) [#37408](https://github.com/nodejs/node/pull/37408) +* \[[`65910c0d6c`](https://github.com/nodejs/node/commit/65910c0d6c)] - **(SEMVER-MAJOR)** **tls**: represent registeredID numerically always (Tobias Nießen) [#41561](https://github.com/nodejs/node/pull/41561) +* \[[`807c7e14f4`](https://github.com/nodejs/node/commit/807c7e14f4)] - **(SEMVER-MAJOR)** **tls**: move tls.parseCertString to end-of-life (Tobias Nießen) [#41479](https://github.com/nodejs/node/pull/41479) +* \[[`f524306077`](https://github.com/nodejs/node/commit/f524306077)] - **(SEMVER-MAJOR)** **url**: throw on NULL in IPv6 hostname (Rich Trott) [#42313](https://github.com/nodejs/node/pull/42313) +* \[[`0187bc5cdc`](https://github.com/nodejs/node/commit/0187bc5cdc)] - **(SEMVER-MAJOR)** **v8**: make v8.writeHeapSnapshot() error codes consistent (Darshan Sen) [#42577](https://github.com/nodejs/node/pull/42577) +* \[[`74b9baa426`](https://github.com/nodejs/node/commit/74b9baa426)] - **(SEMVER-MAJOR)** **v8**: make writeHeapSnapshot throw if fopen fails (Antonio Román) [#41373](https://github.com/nodejs/node/pull/41373) +* \[[`ce4d3adf50`](https://github.com/nodejs/node/commit/ce4d3adf50)] - **(SEMVER-MAJOR)** **worker**: expose BroadcastChannel as a global (James M Snell) [#41271](https://github.com/nodejs/node/pull/41271) +* \[[`6486a304d3`](https://github.com/nodejs/node/commit/6486a304d3)] - **(SEMVER-MAJOR)** **worker**: graduate BroadcastChannel to supported (James M Snell) [#41271](https://github.com/nodejs/node/pull/41271) + +### Semver-Minor Commits + +* \[[`415726b8c4`](https://github.com/nodejs/node/commit/415726b8c4)] - **(SEMVER-MINOR)** **stream**: add writableAborted (Robert Nagy) [#40802](https://github.com/nodejs/node/pull/40802) +* \[[`54819f08e0`](https://github.com/nodejs/node/commit/54819f08e0)] - **(SEMVER-MINOR)** **test\_runner**: support 'only' tests (Colin Ihrig) [#42514](https://github.com/nodejs/node/pull/42514) + +### Semver-Patch Commits + +* \[[`7533d08b94`](https://github.com/nodejs/node/commit/7533d08b94)] - **buffer**: fix `atob` input validation (Austin Kelleher) [#42662](https://github.com/nodejs/node/pull/42662) +* \[[`96673bcb96`](https://github.com/nodejs/node/commit/96673bcb96)] - **build**: run clang-format on CI (Darshan Sen) [#42681](https://github.com/nodejs/node/pull/42681) +* \[[`d5462e4558`](https://github.com/nodejs/node/commit/d5462e4558)] - **build**: reset embedder string to "-node.0" (Michaël Zasso) [#42657](https://github.com/nodejs/node/pull/42657) +* \[[`aa52873887`](https://github.com/nodejs/node/commit/aa52873887)] - **build**: add configure option --v8-enable-short-builtin-calls (daomingq) [#42109](https://github.com/nodejs/node/pull/42109) +* \[[`7ee8a7a463`](https://github.com/nodejs/node/commit/7ee8a7a463)] - **build**: reset embedder string to "-node.0" (Michaël Zasso) [#41610](https://github.com/nodejs/node/pull/41610) +* \[[`a189dee52a`](https://github.com/nodejs/node/commit/a189dee52a)] - **build**: reset embedder string to "-node.0" (Michaël Zasso) [#40907](https://github.com/nodejs/node/pull/40907) +* \[[`e8697cfe38`](https://github.com/nodejs/node/commit/e8697cfe38)] - **crypto**: improve prime size argument validation (Tobias Nießen) [#42234](https://github.com/nodejs/node/pull/42234) +* \[[`a9c0689786`](https://github.com/nodejs/node/commit/a9c0689786)] - **crypto**: fix return type prob reported by coverity (Michael Dawson) [#42135](https://github.com/nodejs/node/pull/42135) +* \[[`e938515b41`](https://github.com/nodejs/node/commit/e938515b41)] - **deps**: patch V8 to 10.1.124.8 (Michaël Zasso) [#42730](https://github.com/nodejs/node/pull/42730) +* \[[`eba7d2db7f`](https://github.com/nodejs/node/commit/eba7d2db7f)] - **deps**: V8: cherry-pick ad21d212fc14 (Michaël Zasso) [#42657](https://github.com/nodejs/node/pull/42657) +* \[[`004137e269`](https://github.com/nodejs/node/commit/004137e269)] - **deps**: V8: cherry-pick 4c29cf1b7885 (Michaël Zasso) [#42657](https://github.com/nodejs/node/pull/42657) +* \[[`a052c03033`](https://github.com/nodejs/node/commit/a052c03033)] - **deps**: V8: cherry-pick ca2a787a0b49 (Michaël Zasso) [#42657](https://github.com/nodejs/node/pull/42657) +* \[[`01cea9a8d8`](https://github.com/nodejs/node/commit/01cea9a8d8)] - **deps**: V8: cherry-pick a2cae2180a7a (Michaël Zasso) [#42657](https://github.com/nodejs/node/pull/42657) +* \[[`d9d26b08ef`](https://github.com/nodejs/node/commit/d9d26b08ef)] - **deps**: V8: cherry-pick 87ce4f5d98a5 (Michaël Zasso) [#42657](https://github.com/nodejs/node/pull/42657) +* \[[`64a6328505`](https://github.com/nodejs/node/commit/64a6328505)] - **deps**: make V8 compilable with older glibc (Michaël Zasso) [#42657](https://github.com/nodejs/node/pull/42657) +* \[[`fde59217b9`](https://github.com/nodejs/node/commit/fde59217b9)] - **deps**: V8: fix v8-cppgc.h for MSVC (Jiawen Geng) [#42657](https://github.com/nodejs/node/pull/42657) +* \[[`cdcc82cced`](https://github.com/nodejs/node/commit/cdcc82cced)] - **deps**: silence V8's warning on CompileFunction (Michaël Zasso) [#40907](https://github.com/nodejs/node/pull/40907) +* \[[`2f51e121da`](https://github.com/nodejs/node/commit/2f51e121da)] - **deps**: update Acorn to v8.7.0 (Michaël Zasso) [#42667](https://github.com/nodejs/node/pull/42667) +* \[[`6d4b01774b`](https://github.com/nodejs/node/commit/6d4b01774b)] - **deps**: update ICU to 71.1 (Michaël Zasso) [#42655](https://github.com/nodejs/node/pull/42655) +* \[[`2d84620f86`](https://github.com/nodejs/node/commit/2d84620f86)] - **deps**: upgrade npm to 8.6.0 (npm team) [#42550](https://github.com/nodejs/node/pull/42550) +* \[[`c7ac11fa25`](https://github.com/nodejs/node/commit/c7ac11fa25)] - **deps**: update undici to 5.0.0 (Node.js GitHub Bot) [#42583](https://github.com/nodejs/node/pull/42583) +* \[[`468fffdf66`](https://github.com/nodejs/node/commit/468fffdf66)] - **deps**: V8: cherry-pick 50d5fb7a457c (Michaël Zasso) [#41610](https://github.com/nodejs/node/pull/41610) +* \[[`48708be57b`](https://github.com/nodejs/node/commit/48708be57b)] - **deps**: V8: cherry-pick 79a9d2eb3477 (Michaël Zasso) [#41610](https://github.com/nodejs/node/pull/41610) +* \[[`3c8782f70e`](https://github.com/nodejs/node/commit/3c8782f70e)] - **deps**: silence V8's warning on CompileFunction (Michaël Zasso) [#40907](https://github.com/nodejs/node/pull/40907) +* \[[`9318408c49`](https://github.com/nodejs/node/commit/9318408c49)] - **deps**: silence V8's warning on CompileFunction (Michaël Zasso) [#40907](https://github.com/nodejs/node/pull/40907) +* \[[`e23e345b6c`](https://github.com/nodejs/node/commit/e23e345b6c)] - **deps**: V8: cherry-pick 80bbbb143c24 (Michaël Zasso) [#40907](https://github.com/nodejs/node/pull/40907) +* \[[`696ce7df26`](https://github.com/nodejs/node/commit/696ce7df26)] - **deps**: V8: cherry-pick 1cc12b278e22 (Michaël Zasso) [#40907](https://github.com/nodejs/node/pull/40907) +* \[[`aa88e5e4b9`](https://github.com/nodejs/node/commit/aa88e5e4b9)] - **doc**: revise data imports and node: imports sections (Rich Trott) [#42734](https://github.com/nodejs/node/pull/42734) +* \[[`a058cefe29`](https://github.com/nodejs/node/commit/a058cefe29)] - **doc**: fix ESM JSON/data URL import example (Rich Trott) [#42728](https://github.com/nodejs/node/pull/42728) +* \[[`e61b62b9d4`](https://github.com/nodejs/node/commit/e61b62b9d4)] - **doc**: improve doc for http.ServerResponse inheritance (Luigi Pinca) [#42693](https://github.com/nodejs/node/pull/42693) +* \[[`6669b3857f`](https://github.com/nodejs/node/commit/6669b3857f)] - **doc**: add RafaelGSS to collaborators (RafaelGSS) [#42718](https://github.com/nodejs/node/pull/42718) +* \[[`f825341bab`](https://github.com/nodejs/node/commit/f825341bab)] - **doc**: add NodeEdKeyGenParams to CryptoKey.algorithm (Tobias Nießen) [#42629](https://github.com/nodejs/node/pull/42629) +* \[[`d4d78361f2`](https://github.com/nodejs/node/commit/d4d78361f2)] - **doc**: fix the example for embedders (Momtchil Momtchev) [#42671](https://github.com/nodejs/node/pull/42671) +* \[[`6706be1cdb`](https://github.com/nodejs/node/commit/6706be1cdb)] - **doc**: change AES-GCM IV recommendation in WebCrypto (Tobias Nießen) [#42611](https://github.com/nodejs/node/pull/42611) +* \[[`4508c8caa4`](https://github.com/nodejs/node/commit/4508c8caa4)] - **doc**: fix `added:` info for some methods (Luigi Pinca) [#42661](https://github.com/nodejs/node/pull/42661) +* \[[`951dbc045a`](https://github.com/nodejs/node/commit/951dbc045a)] - **doc**: remove unneeded new in Buffer example (Niklas Mischkulnig) [#42682](https://github.com/nodejs/node/pull/42682) +* \[[`65e838071b`](https://github.com/nodejs/node/commit/65e838071b)] - **doc**: mark worker.id as integer in cluster docs (Tobias Nießen) [#42684](https://github.com/nodejs/node/pull/42684) +* \[[`a82713cbb6`](https://github.com/nodejs/node/commit/a82713cbb6)] - **doc**: recommend `fh.createWriteStream` for fsPromises methods (Antoine du Hamel) [#42653](https://github.com/nodejs/node/pull/42653) +* \[[`13ad8d4e09`](https://github.com/nodejs/node/commit/13ad8d4e09)] - **doc**: fix outgoingMessage.removeHeader() signature (Luigi Pinca) [#42652](https://github.com/nodejs/node/pull/42652) +* \[[`a0461255c0`](https://github.com/nodejs/node/commit/a0461255c0)] - **doc**: mark tlsSocket.authorized as boolean property (Tobias Nießen) [#42647](https://github.com/nodejs/node/pull/42647) +* \[[`3ac7f86c2b`](https://github.com/nodejs/node/commit/3ac7f86c2b)] - **doc**: add missing punctuation in Web Streams doc (Tobias Nießen) [#42672](https://github.com/nodejs/node/pull/42672) +* \[[`b98386c977`](https://github.com/nodejs/node/commit/b98386c977)] - **doc**: add missing article in session ticket section (Tobias Nießen) [#42632](https://github.com/nodejs/node/pull/42632) +* \[[`a113468383`](https://github.com/nodejs/node/commit/a113468383)] - **doc**: link to dynamic import function (Tobias Nießen) [#42634](https://github.com/nodejs/node/pull/42634) +* \[[`dfc2dc8b65`](https://github.com/nodejs/node/commit/dfc2dc8b65)] - **doc**: add note about header values encoding (Shogun) [#42624](https://github.com/nodejs/node/pull/42624) +* \[[`ec5a359ffd`](https://github.com/nodejs/node/commit/ec5a359ffd)] - **doc**: add missing word in rootCertificates section (Tobias Nießen) [#42633](https://github.com/nodejs/node/pull/42633) +* \[[`c08a361f70`](https://github.com/nodejs/node/commit/c08a361f70)] - **doc**: add history entries for DEP0162 on `fs.md` (Antoine du Hamel) [#42608](https://github.com/nodejs/node/pull/42608) +* \[[`4fade6acb4`](https://github.com/nodejs/node/commit/4fade6acb4)] - **doc**: fix brackets position (Livia Medeiros) [#42649](https://github.com/nodejs/node/pull/42649) +* \[[`8055c7ba5d`](https://github.com/nodejs/node/commit/8055c7ba5d)] - **doc**: copyedit corepack.md (Rich Trott) [#42620](https://github.com/nodejs/node/pull/42620) +* \[[`85a65c3260`](https://github.com/nodejs/node/commit/85a65c3260)] - **doc**: delete chakra tt from diagnostic tooling support tiers (Tony Gorez) [#42627](https://github.com/nodejs/node/pull/42627) +* \[[`63bb6dcf0f`](https://github.com/nodejs/node/commit/63bb6dcf0f)] - **doc**: align links in table to top (nikoladev) [#41396](https://github.com/nodejs/node/pull/41396) +* \[[`28d8614add`](https://github.com/nodejs/node/commit/28d8614add)] - **http**: document that ClientRequest inherits from OutgoingMessage (K.C.Ashish Kumar) [#42642](https://github.com/nodejs/node/pull/42642) +* \[[`c37fdacb34`](https://github.com/nodejs/node/commit/c37fdacb34)] - **lib**: use class fields in observe.js (Joyee Cheung) [#42361](https://github.com/nodejs/node/pull/42361) +* \[[`ea0668a27e`](https://github.com/nodejs/node/commit/ea0668a27e)] - **lib**: use class fields in Event and EventTarget (Joyee Cheung) [#42361](https://github.com/nodejs/node/pull/42361) +* \[[`eb7b89c829`](https://github.com/nodejs/node/commit/eb7b89c829)] - **lib**: update class fields TODO in abort\_controller.js (Joyee Cheung) [#42361](https://github.com/nodejs/node/pull/42361) +* \[[`d835b1f1c1`](https://github.com/nodejs/node/commit/d835b1f1c1)] - **meta**: update AUTHORS (Node.js GitHub Bot) [#42677](https://github.com/nodejs/node/pull/42677) +* \[[`29492496e8`](https://github.com/nodejs/node/commit/29492496e8)] - **meta**: move one or more collaborators to emeritus (Node.js GitHub Bot) [#42599](https://github.com/nodejs/node/pull/42599) +* \[[`93c4dc5e5a`](https://github.com/nodejs/node/commit/93c4dc5e5a)] - **module**: ensure 'node:'-only modules can access node\_modules (Colin Ihrig) [#42430](https://github.com/nodejs/node/pull/42430) +* \[[`3a26db9697`](https://github.com/nodejs/node/commit/3a26db9697)] - **net**: make `server.address()` return an integer for `family` (Antoine du Hamel) [#41431](https://github.com/nodejs/node/pull/41431) +* \[[`44fdf953ba`](https://github.com/nodejs/node/commit/44fdf953ba)] - **node-api,src**: fix module registration in MSVC C++ (Vladimir Morozov) [#42459](https://github.com/nodejs/node/pull/42459) +* \[[`3026ca0bf2`](https://github.com/nodejs/node/commit/3026ca0bf2)] - **src**: fix coverity report (Michael Dawson) [#42663](https://github.com/nodejs/node/pull/42663) +* \[[`01fd048c6e`](https://github.com/nodejs/node/commit/01fd048c6e)] - **src**: update NODE\_MODULE\_VERSION to 108 (Michaël Zasso) [#42657](https://github.com/nodejs/node/pull/42657) +* \[[`75a71dc7ae`](https://github.com/nodejs/node/commit/75a71dc7ae)] - **src**: fix alphabetically sorted binding list (Tobias Nießen) [#42687](https://github.com/nodejs/node/pull/42687) +* \[[`457567f72c`](https://github.com/nodejs/node/commit/457567f72c)] - **src**: include crypto in the bootstrap snapshot (Joyee Cheung) [#42203](https://github.com/nodejs/node/pull/42203) +* \[[`aa7dc808f5`](https://github.com/nodejs/node/commit/aa7dc808f5)] - **src**: update ImportModuleDynamically (Camillo Bruni) [#41610](https://github.com/nodejs/node/pull/41610) +* \[[`fa0439e66c`](https://github.com/nodejs/node/commit/fa0439e66c)] - **src**: update NODE\_MODULE\_VERSION to 105 (Michaël Zasso) [#41610](https://github.com/nodejs/node/pull/41610) +* \[[`6ec1664dc8`](https://github.com/nodejs/node/commit/6ec1664dc8)] - **src**: update NODE\_MODULE\_VERSION to 104 (Michaël Zasso) [#40907](https://github.com/nodejs/node/pull/40907) +* \[[`a706342368`](https://github.com/nodejs/node/commit/a706342368)] - **src**: add kNoBrowserGlobals flag for Environment (Cheng Zhao) [#40532](https://github.com/nodejs/node/pull/40532) +* \[[`0c57a37dd0`](https://github.com/nodejs/node/commit/0c57a37dd0)] - **src,crypto**: remove uses of AllocatedBuffer from crypto\_tls.cc (Darshan Sen) [#42589](https://github.com/nodejs/node/pull/42589) +* \[[`be01185844`](https://github.com/nodejs/node/commit/be01185844)] - **src,inspector**: fix empty MaybeLocal crash (Darshan Sen) [#42409](https://github.com/nodejs/node/pull/42409) +* \[[`340b770d3f`](https://github.com/nodejs/node/commit/340b770d3f)] - **stream**: unify writableErrored and readableErrored (Robert Nagy) [#40799](https://github.com/nodejs/node/pull/40799) +* \[[`19064bec34`](https://github.com/nodejs/node/commit/19064bec34)] - **test**: delete test/pummel/test-repl-empty-maybelocal-crash.js (Darshan Sen) [#42720](https://github.com/nodejs/node/pull/42720) +* \[[`9d6af7d1fe`](https://github.com/nodejs/node/commit/9d6af7d1fe)] - **test**: improve `internal/url.js` coverage (Yoshiki Kurihara) [#42650](https://github.com/nodejs/node/pull/42650) +* \[[`d49df5ca8d`](https://github.com/nodejs/node/commit/d49df5ca8d)] - **test**: adapt message tests for V8 10.2 (Michaël Zasso) [#42657](https://github.com/nodejs/node/pull/42657) +* \[[`c6b4e9604f`](https://github.com/nodejs/node/commit/c6b4e9604f)] - **test**: adapt test-worker-debug for V8 10.0 (Michaël Zasso) [#42657](https://github.com/nodejs/node/pull/42657) +* \[[`0854fce8bc`](https://github.com/nodejs/node/commit/0854fce8bc)] - **test**: adapt test-v8-serdes for V8 9.9 (Michaël Zasso) [#42657](https://github.com/nodejs/node/pull/42657) +* \[[`73d53fe9f5`](https://github.com/nodejs/node/commit/73d53fe9f5)] - **test**: only skip slow tests on Raspberry Pi devices (Richard Lau) [#42645](https://github.com/nodejs/node/pull/42645) +* \[[`db7fa9f4b7`](https://github.com/nodejs/node/commit/db7fa9f4b7)] - **test**: allow numeric string for lookupService test (Daeyeon Jeong) [#42596](https://github.com/nodejs/node/pull/42596) +* \[[`0525a147b2`](https://github.com/nodejs/node/commit/0525a147b2)] - **test**: remove an unnecessary `undefined` in wpt (Khaidi Chu) [#41470](https://github.com/nodejs/node/pull/41470) +* \[[`bb762c5bd0`](https://github.com/nodejs/node/commit/bb762c5bd0)] - **test**: simplify test-http-write-callbacks.js (Tobias Nießen) [#42628](https://github.com/nodejs/node/pull/42628) +* \[[`1600869eb7`](https://github.com/nodejs/node/commit/1600869eb7)] - **test**: fix comments in test files (Daeyeon Jeong) [#42536](https://github.com/nodejs/node/pull/42536) +* \[[`82181bb9b8`](https://github.com/nodejs/node/commit/82181bb9b8)] - **test**: fix failure in test/sequential/test-heapdump.js (Darshan Sen) [#41772](https://github.com/nodejs/node/pull/41772) +* \[[`ba5b5acaf1`](https://github.com/nodejs/node/commit/ba5b5acaf1)] - **test**: improve `worker_threads ` coverage (Erick Wendel) [#41818](https://github.com/nodejs/node/pull/41818) +* \[[`f076c36335`](https://github.com/nodejs/node/commit/f076c36335)] - **tools**: update clang-format 1.6.0 to 1.7.0 (Rich Trott) [#42724](https://github.com/nodejs/node/pull/42724) +* \[[`45162bf9e7`](https://github.com/nodejs/node/commit/45162bf9e7)] - **tools**: update clang-format from 1.2.3 to 1.6.0 (Rich Trott) [#42685](https://github.com/nodejs/node/pull/42685) +* \[[`40bc08089d`](https://github.com/nodejs/node/commit/40bc08089d)] - **tools**: update V8 gypfiles for 10.1 (Michaël Zasso) [#42657](https://github.com/nodejs/node/pull/42657) +* \[[`09513cd1a3`](https://github.com/nodejs/node/commit/09513cd1a3)] - **tools**: update eslint to 8.13.0 (Node.js GitHub Bot) [#42678](https://github.com/nodejs/node/pull/42678) +* \[[`b99bb57416`](https://github.com/nodejs/node/commit/b99bb57416)] - **tools**: update gyp-next to v0.12.1 (Michaël Zasso) [#42625](https://github.com/nodejs/node/pull/42625) +* \[[`2468db1f53`](https://github.com/nodejs/node/commit/2468db1f53)] - **tools**: update lint-md-dependencies to @rollup/plugin-commonjs\@21.0.3 (Node.js GitHub Bot) [#42584](https://github.com/nodejs/node/pull/42584) +* \[[`8a3f28a05c`](https://github.com/nodejs/node/commit/8a3f28a05c)] - **tools**: add v8-embedder-state-scope.h to distributed headers (Michaël Zasso) [#41610](https://github.com/nodejs/node/pull/41610) +* \[[`30c4e1d952`](https://github.com/nodejs/node/commit/30c4e1d952)] - **tools**: update V8 gypfiles for 9.8 (Michaël Zasso) [#41610](https://github.com/nodejs/node/pull/41610) +* \[[`1ad44094a2`](https://github.com/nodejs/node/commit/1ad44094a2)] - **tools**: update V8 gypfiles for 9.7 (Michaël Zasso) [#40907](https://github.com/nodejs/node/pull/40907) +* \[[`86b77f7d0f`](https://github.com/nodejs/node/commit/86b77f7d0f)] - **tools,doc**: use V8::DisposePlatform (Michaël Zasso) [#41610](https://github.com/nodejs/node/pull/41610) +* \[[`62e62757b3`](https://github.com/nodejs/node/commit/62e62757b3)] - **tools,test**: fix V8 initialization order (Camillo Bruni) [#42657](https://github.com/nodejs/node/pull/42657) +* \[[`0187bc5cdc`](https://github.com/nodejs/node/commit/0187bc5cdc)] - **v8**: make v8.writeHeapSnapshot() error codes consistent (Darshan Sen) [#42577](https://github.com/nodejs/node/pull/42577) +* \[[`74b9baa426`](https://github.com/nodejs/node/commit/74b9baa426)] - **v8**: make writeHeapSnapshot throw if fopen fails (Antonio Román) [#41373](https://github.com/nodejs/node/pull/41373) + +Windows 64-bit Installer: https://nodejs.org/dist/v18.0.0/node-v18.0.0-x64.msi
+Windows 64-bit Binary: https://nodejs.org/dist/v18.0.0/win-x64/node.exe
+macOS 64-bit Installer: https://nodejs.org/dist/v18.0.0/node-v18.0.0.pkg
+macOS Apple Silicon 64-bit Binary: https://nodejs.org/dist/v18.0.0/node-v18.0.0-darwin-arm64.tar.gz
+macOS Intel 64-bit Binary: https://nodejs.org/dist/v18.0.0/node-v18.0.0-darwin-x64.tar.gz
+Linux 64-bit Binary: https://nodejs.org/dist/v18.0.0/node-v18.0.0-linux-x64.tar.xz
+Linux PPC LE 64-bit Binary: https://nodejs.org/dist/v18.0.0/node-v18.0.0-linux-ppc64le.tar.xz
+Linux s390x 64-bit Binary: https://nodejs.org/dist/v18.0.0/node-v18.0.0-linux-s390x.tar.xz
+AIX 64-bit Binary: https://nodejs.org/dist/v18.0.0/node-v18.0.0-aix-ppc64.tar.gz
+ARMv7 32-bit Binary: https://nodejs.org/dist/v18.0.0/node-v18.0.0-linux-armv7l.tar.xz
+ARMv8 64-bit Binary: https://nodejs.org/dist/v18.0.0/node-v18.0.0-linux-arm64.tar.xz
+Source Code: https://nodejs.org/dist/v18.0.0/node-v18.0.0.tar.gz
+Other release files: https://nodejs.org/dist/v18.0.0/
+Documentation: https://nodejs.org/docs/v18.0.0/api/ + +### SHASUMS + +``` +-----BEGIN PGP SIGNED MESSAGE----- +Hash: SHA256 + +01f2e194074e209340c7b7320bbb568829120c7747d469214ec76413d950bced node-v18.0.0-aix-ppc64.tar.gz +35c05023a5d1ca647e2364e7383b6cf6299e8fed648b03597ca9be52ed0c4d59 node-v18.0.0-darwin-arm64.tar.gz +7aaaef3814316f61b7378c0cc78e0b2360291d746b6314b18197c0ea83caff70 node-v18.0.0-darwin-arm64.tar.xz +cf94dd0dc95574775769de7ed7cea5a44a99bb813ab786fb90f764c17555b505 node-v18.0.0-darwin-x64.tar.gz +29a29ecb65a724d17ad81080fd199a012c120b5665d443b77c9f229f355a1da8 node-v18.0.0-darwin-x64.tar.xz +3c7b18da62c175e9e4767f2911a0ec002f3b7bdac38f0d3bb1c5405acded1b86 node-v18.0.0-headers.tar.gz +885a1d43d8db95bd623bc3d3eba21563555cce2c35e30f380b99611ebbed1d50 node-v18.0.0-headers.tar.xz +dc59b5191e2bffcb124e80e12a323b5f700c1fa57a83a1846531008aba1e154d node-v18.0.0-linux-arm64.tar.gz +e91baabfccaecc41aa69eb5580ae4a74730862c562c748a4691a8b2a0d594b88 node-v18.0.0-linux-arm64.tar.xz +a537fbc8da1074231f7cc1502b0708245ad580d8d7bc11cd593c717d4b4f6daf node-v18.0.0-linux-armv7l.tar.gz +7f677912de32d02ce028cf135fd6b90a6a3d9e0e14a91ed23b67a8e3283c2157 node-v18.0.0-linux-armv7l.tar.xz +e04b6bde107a437d1b7c5f7b1701101a2e4ba975626ff81bd0b1cb41ed6def3f node-v18.0.0-linux-ppc64le.tar.gz +1ea9946c56fda3ff7bbed2645cb6ce48312304d8a382ffee823eae5ab4b30601 node-v18.0.0-linux-ppc64le.tar.xz +226b67db4361abc10037c7fb422914bc7e571a6a6524cba54d52ccd48a3bdb5b node-v18.0.0-linux-s390x.tar.gz +8ffe7b8c14738784a9b83afa3d76aa76d7cd7be15539940717021be78ed4ae6c node-v18.0.0-linux-s390x.tar.xz +6260d3526dff25d43451ea8e90e0174975b4cd067e8535dc1d85a6d6b29f3043 node-v18.0.0-linux-x64.tar.gz +ffe94f0a3804e186b53f9480f4ef3a0c9ec450d7da45526438f6d37be9f4d22e node-v18.0.0-linux-x64.tar.xz +0d583340918e1bc8635996f2ea2c4cd2cfbc6ddc422bd79eeede4e0163d7e463 node-v18.0.0.pkg +7280a4318574131e9172c7b64e3dd1f2ee0a7bd132a53a6e98865f7b08db062c node-v18.0.0.tar.gz +344d0e6540b524c69a979ff5c3e78cda7254fd72c03699926beb0b8558b8ce75 node-v18.0.0.tar.xz +e69fc12e086eadf24ccfc4ef89c9bf921fb9034d1e0dd65bf25202a5d6ef2beb node-v18.0.0-win-x64.7z +4864dbd9ca651cd7e36c540e164c5a742517920764dd9c00bb3430a08b5b85ba node-v18.0.0-win-x64.zip +50678d8ff78b54a090e907f427e947260639ce581e2beb4f186550101fea5b2a node-v18.0.0-x64.msi +6a19dbaf04fa10f9b9e8dbe700300a75808670b88f7f96d25f665f70d1a05938 win-x64/node.exe +96617e57a0a4b7ccb7f8324aa6a986d46f4a2f7d4c1789b8863b0e959b62625e win-x64/node.lib +a9338207f3efaf34814852aa663886d34d666cd9df47c2d8e20d4428da08a6f0 win-x64/node_pdb.7z +a2ea39717bcbb7c6593f1398418682e7723e130fa1d8e52763396d02b8bdc281 win-x64/node_pdb.zip +-----BEGIN PGP SIGNATURE----- + +iQEzBAEBCAAdFiEETtd49TnjY0x3nIfG1wYoSKGrAFwFAmJe2zcACgkQ1wYoSKGr +AFzX4wgAutuD7Tjo6N+orKAenhC4f/M+eSnqxlzwkLkdlqmClh01zu7Guhwhg0FS +iZu1WsVbU1uQzWHQrIrxhz5+cZQ1LdcpJShOjwpZ0hs9bOAjGxU0TPdtFEJKx1bK +QsG+IHlZ5O2f73MxHFAsyYz1FTRSWHf5+qkW63lpWig0Q868R4hptx396tf7DGLX +B7LcsUeZnlOPhaeGmJSEzZHcohIfu1IvZNqx6MuC7DgA3pIgeeQ//Ku0/oNlha4r +nmIo4zIja7LJHxteAIZJDd9LZ9k9rx02Doq1dFAKIpQ05+lz6zjKqki4BMipfRUx +kCuHMXLs/S2qu1UospDCnjv6Jit6rA== +=Wn8F +-----END PGP SIGNATURE----- + +``` diff --git a/locale/en/docs/guides/event-loop-timers-and-nexttick.md b/locale/en/docs/guides/event-loop-timers-and-nexttick.md index 54e6a4710f53..bc9986ce725f 100644 --- a/locale/en/docs/guides/event-loop-timers-and-nexttick.md +++ b/locale/en/docs/guides/event-loop-timers-and-nexttick.md @@ -444,19 +444,18 @@ the event loop to proceed, it must hit the **poll** phase, which means there is a non-zero chance that a connection could have been received allowing the connection event to be fired before the listening event. -Another example is running a function constructor that was to, say, -inherit from `EventEmitter` and it wanted to call an event within the -constructor: +Another example is inheriting from `EventEmitter` and emitting an +event from within the constructor: ```js const EventEmitter = require('events'); -const util = require('util'); -function MyEmitter() { - EventEmitter.call(this); - this.emit('event'); +class MyEmitter extends EventEmitter { + constructor() { + super(); + this.emit('event'); + } } -util.inherits(MyEmitter, EventEmitter); const myEmitter = new MyEmitter(); myEmitter.on('event', () => { @@ -472,17 +471,17 @@ after the constructor has finished, which provides the expected results: ```js const EventEmitter = require('events'); -const util = require('util'); -function MyEmitter() { - EventEmitter.call(this); +class MyEmitter extends EventEmitter { + constructor() { + super(); - // use nextTick to emit the event once a handler is assigned - process.nextTick(() => { - this.emit('event'); - }); + // use nextTick to emit the event once a handler is assigned + process.nextTick(() => { + this.emit('event'); + }); + } } -util.inherits(MyEmitter, EventEmitter); const myEmitter = new MyEmitter(); myEmitter.on('event', () => { diff --git a/locale/en/download/package-manager.md b/locale/en/download/package-manager.md index e3edb9ab0393..459567376a6e 100644 --- a/locale/en/download/package-manager.md +++ b/locale/en/download/package-manager.md @@ -30,7 +30,7 @@ title: Installing Node.js via package manager * [Snap](#snap) * [Solus](#solus) * [Void Linux](#void-linux) -* [Windows](#windows) +* [Windows](#windows-1) * [z/OS](#zos) --- diff --git a/locale/en/get-involved/node-meetups.md b/locale/en/get-involved/node-meetups.md index bea4045bd97c..f4a56705a617 100644 --- a/locale/en/get-involved/node-meetups.md +++ b/locale/en/get-involved/node-meetups.md @@ -384,6 +384,16 @@ REQUIREMENTS * Organizer name - Alex Fernández * Organizer contact info - +### Sweden + +#### Stockholm + +* [Meetup](https://www.meetup.com/node-js-stockholm/) +* Frequency of meetups - quarterly meetings +* How to submit a talk? Contact organizers in the meetup page. +* Organizer name - Aleksandar Marinkovic +* Organizer contact info - + ### Thailand #### Bangkok diff --git a/locale/en/knowledge/HTTP/servers/how-to-create-a-HTTPS-server.md b/locale/en/knowledge/HTTP/servers/how-to-create-a-HTTPS-server.md index aa08eba426f7..3a5785f4a979 100644 --- a/locale/en/knowledge/HTTP/servers/how-to-create-a-HTTPS-server.md +++ b/locale/en/knowledge/HTTP/servers/how-to-create-a-HTTPS-server.md @@ -9,7 +9,7 @@ layout: knowledge-post.hbs To create an HTTPS server, you need two things: an SSL certificate, and built-in `https` Node.js module. -We need to start out with a word about SSL certificates. Speaking generally, there are two kinds of certificates: those signed by a 'Certificate Authority', or CA, and 'self-signed certificates'. A Certificate Authority is a trusted source for an SSL certificate, and using a certificate from a CA allows your users to be trust the identity of your website. In most cases, you would want to use a CA-signed certificate in a production environment - for testing purposes, however, a self-signed certificate will do just fine. +We need to start out with a word about SSL certificates. Speaking generally, there are two kinds of certificates: those signed by a 'Certificate Authority', or CA, and 'self-signed certificates'. A Certificate Authority is a trusted source for an SSL certificate, and using a certificate from a CA allows your users to trust the identity of your website. In most cases, you would want to use a CA-signed certificate in a production environment - for testing purposes, however, a self-signed certificate will do just fine. To generate a self-signed certificate, run the following in your shell: diff --git a/locale/en/knowledge/getting-started/control-flow/what-are-event-emitters.md b/locale/en/knowledge/getting-started/control-flow/what-are-event-emitters.md index 88bbd347435f..62c30f5b4b1d 100644 --- a/locale/en/knowledge/getting-started/control-flow/what-are-event-emitters.md +++ b/locale/en/knowledge/getting-started/control-flow/what-are-event-emitters.md @@ -45,7 +45,7 @@ In the `print` event, note that we pass an extra parameter - all the extra param If you use the method `once` instead of `on`, after the callback is fired, it is removed from the list of callbacks. A handy little function if you want to detect only the first time an event has been emitted. -If you want remove a specific callback, you can use `removeListener`. If you want to remove all callbacks to a specific event, you can use `removeAllListeners`. +If you want to remove a specific callback, you can use `removeListener`. If you want to remove all callbacks to a specific event, you can use `removeAllListeners`. ```javascript var EventEmitter = require('events').EventEmitter, @@ -106,4 +106,4 @@ true false ``` -NOTE: If you want create more than 10 listeners on a single event, you will have to make a call to `ee.setMaxListeners(n)` where n is the max numbers of listeners (with zero being unlimited number of listeners). This is used to make sure you aren't accidentally leaking event listeners. +NOTE: If you want to create more than 10 listeners on a single event, you will have to make a call to `ee.setMaxListeners(n)` where n is the max numbers of listeners (with zero being unlimited number of listeners). This is used to make sure you aren't accidentally leaking event listeners. diff --git a/locale/en/site.json b/locale/en/site.json index f0f9aa82eb0c..3cf4e204af3c 100644 --- a/locale/en/site.json +++ b/locale/en/site.json @@ -163,10 +163,10 @@ }, "banners": { "index": { - "startDate": "2022-03-14T12:00:00.000Z", - "endDate": "2022-03-24T12:00:00.000Z", - "text": "New security releases available", - "link": "https://nodejs.org/en/blog/vulnerability/mar-2022-security-releases/" + "startDate": "2022-04-19T15:45:00.000Z", + "endDate": "2022-04-26T16:00:00.000Z", + "text": "Node.js 18 is now available!", + "link": "https://nodejs.org/en/blog/announcements/v18-release-announce" }, "blacklivesmatter": { "visible": false, diff --git a/locale/es/download/package-manager.md b/locale/es/download/package-manager.md index 62a7e7e366ba..bf1a8eef3a78 100644 --- a/locale/es/download/package-manager.md +++ b/locale/es/download/package-manager.md @@ -24,7 +24,7 @@ title: Instalando Node.js utilizando un gestor de paquetes * [SmartOS y illumos](#smartos-and-illumos) * [Solus](#solus) * [Void Linux](#void-linux) -* [Windows](#windows) +* [Windows](#windows-1) --- diff --git a/locale/ko/download/package-manager.md b/locale/ko/download/package-manager.md index 7defb8b5e3b0..00e93a4f4703 100644 --- a/locale/ko/download/package-manager.md +++ b/locale/ko/download/package-manager.md @@ -51,7 +51,7 @@ title: 패키지 매니저로 Node.js 설치하기 * [SmartOS 와 illumos](#smartos-and-illumos) * [Solus](#solus) * [Void Linux](#void-linux) -* [Windows](#windows) +* [Windows](#windows-1) --- diff --git a/locale/pt-br/download/package-manager.md b/locale/pt-br/download/package-manager.md index 68718eaffef1..e012cb930358 100644 --- a/locale/pt-br/download/package-manager.md +++ b/locale/pt-br/download/package-manager.md @@ -23,7 +23,7 @@ title: Instalando Node.js via gerenciador pacotes * [SmartOS e illumos](#smartos-and-illumos) * [Solus](#solus) * [Void Linux](#void-linux) -* [Windows](#windows) +* [Windows](#windows-1) --- diff --git a/locale/ro/download/package-manager.md b/locale/ro/download/package-manager.md index 8b3166aefa21..56de790eeef1 100644 --- a/locale/ro/download/package-manager.md +++ b/locale/ro/download/package-manager.md @@ -24,7 +24,7 @@ title: Installing Node.js via package manager * [SmartOS and illumos](#smartos-and-illumos) * [Solus](#solus) * [Void Linux](#void-linux) -* [Windows](#windows) +* [Windows](#windows-1) --- diff --git a/locale/ru/download/package-manager.md b/locale/ru/download/package-manager.md index 22dadb6f382c..347bd4abf4a3 100644 --- a/locale/ru/download/package-manager.md +++ b/locale/ru/download/package-manager.md @@ -23,7 +23,7 @@ title: Установка Node.js через пакетный менеджер * [SmartOS и illumos](#smartos-and-illumos) * [Solus](#solus) * [Void Linux](#void-linux) -* [Windows](#windows) +* [Windows](#windows-1) --- diff --git a/locale/zh-cn/download/package-manager.md b/locale/zh-cn/download/package-manager.md index 7b4f20e14597..a452e700ebb7 100644 --- a/locale/zh-cn/download/package-manager.md +++ b/locale/zh-cn/download/package-manager.md @@ -26,7 +26,7 @@ title: 通过包管理器安装 Node.js * [SmartOS 和 illumos](#smartos-and-illumos) * [Solus](#solus) * [Void Linux](#void-linux) -* [Windows](#windows) +* [Windows](#windows-1) * [z/OS](#zos) --- diff --git a/locale/zh-cn/site.json b/locale/zh-cn/site.json index a08943a5fc73..0e65c4b9ec31 100644 --- a/locale/zh-cn/site.json +++ b/locale/zh-cn/site.json @@ -163,7 +163,7 @@ }, "banners": { "index": { - "text": "OpenSSL 安全更新已可用" + "text": "Node.js 18 现已可用!" } } } diff --git a/locale/zh-tw/download/package-manager.md b/locale/zh-tw/download/package-manager.md index fcb051c29695..43c6cad7aede 100644 --- a/locale/zh-tw/download/package-manager.md +++ b/locale/zh-tw/download/package-manager.md @@ -24,7 +24,7 @@ title: 使用套件管理器安裝 Node.js * [SmartOS 及 illumos](#smartos-and-illumos) * [Solus](#solus) * [Void Linux](#void-linux) -* [Windows](#windows) +* [Windows](#windows-1) --- diff --git a/server.js b/server.js index bf1468ee067d..d061d6fb2860 100644 --- a/server.js +++ b/server.js @@ -3,7 +3,7 @@ // The server where the site is exposed through a static file server // while developing locally. -const fs = require('fs'); +const fs = require('fs/promises'); const http = require('http'); const path = require('path'); const chokidar = require('chokidar'); @@ -48,21 +48,18 @@ function getLocale(filePath) { // This function has two meanings: // 1. Build for the specific language. // 2. Choose what languages for the menu. -function dynamicallyBuildOnLanguages(source, locale) { +async function dynamicallyBuildOnLanguages(source, locale) { + let localesData = null; + if (!selectedLocales || selectedLocales.length === 0) { - fs.readdir(path.join(__dirname, 'locale'), (err, locales) => { - if (err) { - throw err; - } - - const filteredLocales = locales.filter((file) => junk.not(file)); - const localesData = build.generateLocalesData(filteredLocales); - build.buildLocale(source, locale, { preserveLocale, localesData }); - }); + const localesPath = path.join(__dirname, 'locale'); + const locales = await fs.readdir(localesPath); + const filteredLocales = locales.filter((file) => junk.not(file)); + localesData = build.generateLocalesData(filteredLocales); } else { - const localesData = build.generateLocalesData(selectedLocales); - build.buildLocale(source, locale, { preserveLocale, localesData }); + localesData = build.generateLocalesData(selectedLocales); } + build.buildLocale(source, locale, { preserveLocale, localesData }); } build.getSource((err, source) => { @@ -70,23 +67,23 @@ build.getSource((err, source) => { throw err; } - locales.on('change', (filePath) => { + locales.on('change', async (filePath) => { const locale = getLocale(filePath); if (!selectedLocales || selectedLocales.includes(locale)) { console.log( `The language ${locale} is changed, '${filePath}' is modified.` ); - dynamicallyBuildOnLanguages(source, locale); + await dynamicallyBuildOnLanguages(source, locale); } }); - locales.on('add', (filePath) => { + locales.on('add', async (filePath) => { const locale = getLocale(filePath); if (!selectedLocales || selectedLocales.includes(locale)) { console.log(`The language ${locale} is changed, '${filePath}' is added.`); - dynamicallyBuildOnLanguages(source, locale); + await dynamicallyBuildOnLanguages(source, locale); locales.add(filePath); } }); diff --git a/source/nodejsVersions.md b/source/nodejsVersions.md index dfb7e2c6890b..cde1fc9cc578 100644 --- a/source/nodejsVersions.md +++ b/source/nodejsVersions.md @@ -3,6 +3,7 @@ 'locale' folder at 'docs/index.md' to replace the variable in order to avoid missing adding Node.js links. --> +* [Node.js 17.x](https://nodejs.org/docs/latest-v17.x/api/) * [Node.js 15.x](https://nodejs.org/docs/latest-v15.x/api/) * [Node.js 14.x](https://nodejs.org/docs/latest-v14.x/api/) * [Node.js 13.x](https://nodejs.org/docs/latest-v13.x/api/)