This repository was archived by the owner on Oct 12, 2022. It is now read-only.
support sourcemaps in vm.runIn*Context#22
Closed
hayes wants to merge 1 commit into
Closed
Conversation
Contributor
|
@hayes This looks very interesting. I hope to find some time over the holidays to try this... Right now we are finishing the December release. |
Author
|
This is very out of date, and probably can be made to work much better with the node2 debugger. Going to close this and create a new PR if I ever find a need or have the time |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Currently the node debugger requires that you compile your code with sourcemaps and save the compile source to the filesystem in order for sourcemaps to work.
It would be really cool, and useful, if it could also support runtime compilation. This would allow launching an application with a tool that patches require to automatically compiles files as they are required. It could also allow debugging of dynamically generated code (but thats a more complicated topic).
I spiked out something that works. It probably still needs some work, but wanted to get some initial feedback, and see if it is something you would consider merging into the debugger before I do too much more work on it.
I also created a minimal test case to demonstrate what I am trying to support.
clone: https://github.com/yavascript/runtime-compile-debug-example
npm install. start debug server, and set a breakpoint in foo.es6. run the launch script. this will not break on master, but should work on my branch.