Skip to content

Commit

Permalink
doc: fix link and history of SourceMap sections
Browse files Browse the repository at this point in the history
PR-URL: #57098
Fixes: #57094
Refs: #48461
Refs: #47790
Reviewed-By: Chengzhong Wu <[email protected]>
Reviewed-By: Jacob Smith <[email protected]>
Reviewed-By: James M Snell <[email protected]>
  • Loading branch information
aduh95 committed Feb 18, 2025
1 parent de5cbdc commit 402bf16
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 2 deletions.
11 changes: 11 additions & 0 deletions doc/api/module.md
Original file line number Diff line number Diff line change
Expand Up @@ -1033,6 +1033,13 @@ added:
#### `new SourceMap(payload[, { lineLengths }])`
<!-- YAML
changes:
- version: v20.5.0
pr-url: https://github.com/nodejs/node/pull/48461

Check warning on line 1039 in doc/api/module.md

View workflow job for this annotation

GitHub Actions / lint-pr-url

pr-url doesn't match the URL of the current PR.
description: Add support for `lineLengths`.
-->
* `payload` {Object}
* `lineLengths` {number\[]}
Expand Down Expand Up @@ -1095,6 +1102,10 @@ columnNumber)`
#### `sourceMap.findOrigin(lineNumber, columnNumber)`
<!-- YAML
added: v20.4.0
-->
* `lineNumber` {number} The 1-indexed line number of the call
site in the generated source
* `columnNumber` {number} The 1-indexed column number
Expand Down
4 changes: 2 additions & 2 deletions doc/api/modules.md
Original file line number Diff line number Diff line change
Expand Up @@ -1151,9 +1151,9 @@ This section was moved to

* <a id="modules_module_findsourcemap_path_error" href="module.html#modulefindsourcemappath">`module.findSourceMap(path)`</a>
* <a id="modules_class_module_sourcemap" href="module.html#class-modulesourcemap">Class: `module.SourceMap`</a>
* <a id="modules_new_sourcemap_payload" href="module.html#new-sourcemappayload">`new SourceMap(payload)`</a>
* <a id="modules_new_sourcemap_payload" href="module.html#new-sourcemappayload--linelengths-">`new SourceMap(payload)`</a>
* <a id="modules_sourcemap_payload" href="module.html#sourcemappayload">`sourceMap.payload`</a>
* <a id="modules_sourcemap_findentry_linenumber_columnnumber" href="module.html#sourcemapfindentrylinenumber-columnnumber">`sourceMap.findEntry(lineNumber, columnNumber)`</a>
* <a id="modules_sourcemap_findentry_linenumber_columnnumber" href="module.html#sourcemapfindentrylineoffset-columnoffset">`sourceMap.findEntry(lineNumber, columnNumber)`</a>

[Determining module system]: packages.md#determining-module-system
[ECMAScript Modules]: esm.md
Expand Down

0 comments on commit 402bf16

Please sign in to comment.