diff --git a/doc/api/process.md b/doc/api/process.md index e9ef0a972de01c..a7594aa205b57d 100644 --- a/doc/api/process.md +++ b/doc/api/process.md @@ -2375,7 +2375,7 @@ console.log(memoryUsage.rss()); ``` ```cjs -const { rss } = require('node:process'); +const { memoryUsage } = require('node:process'); console.log(memoryUsage.rss()); // 35655680 @@ -2960,6 +2960,7 @@ present. ```mjs import { report } from 'node:process'; +import util from 'node:util'; const data = report.getReport(); console.log(data.header.nodejsVersion); @@ -2971,6 +2972,7 @@ fs.writeFileSync('my-report.log', util.inspect(data), 'utf8'); ```cjs const { report } = require('node:process'); +const util = require('node:util'); const data = report.getReport(); console.log(data.header.nodejsVersion);