-
Notifications
You must be signed in to change notification settings - Fork 29.8k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
module: add SourceMap.lineLengths #48461
module: add SourceMap.lineLengths #48461
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can you update the documentation as well?
b2376cf
to
5873274
Compare
The failing tests in CI are a bit confusing, these all pass locally, and it looks like they're not running with source maps enabled for some reason. I'm not sure why anything I did there would have changed that though. |
5873274
to
11b3b96
Compare
11b3b96
to
da4b63a
Compare
da4b63a
to
1485dc8
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM % one nit.
doc/api/module.md
Outdated
@@ -274,6 +274,7 @@ added: | |||
#### `new SourceMap(payload)` |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The function signature should be updated to include the optional parameter too.
#### `new SourceMap(payload)` | |
#### `new SourceMap(payload[, lineLengths])` |
As the generated code line lengths property is not part of the source maps spec, would it be more prudent to set the property with an option bag instead of a positional parameter?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
would it be more prudent to set the property with an option bag instead of a positional parameter?
No strong opinions here, but it's a pita to change this kind of thing later, so I'm feeling like it's probably a good idea, too. Anyone else wanna weight on it?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@bcoe would you mind taking a look at this PR? Thank you!
Document lineLengths argument Make lineLengths part of an option bag rather than a positional arg
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
Landed in 9053943 |
Fix: #48460 PR-URL: #48461 Fixes: #48460 Reviewed-By: Chengzhong Wu <[email protected]>
Fix: nodejs#48460 PR-URL: nodejs#48461 Fixes: nodejs#48460 Reviewed-By: Chengzhong Wu <[email protected]>
Fix: nodejs#48460 PR-URL: nodejs#48461 Fixes: nodejs#48460 Reviewed-By: Chengzhong Wu <[email protected]>
This commit does not land cleanly on |
This is another PR that should have been labeled semver-minor. |
Fix: #48460