-
-
Notifications
You must be signed in to change notification settings - Fork 2.3k
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
Added --source-root option for sourcemaps #1100
Conversation
Wait, why is this necessary? I believe we already inline the full source code into the source map so dev tools doesn't need to request it. |
#1078 inlining is not enough in some usecases, and devtools is not the only consumer of sourcemaps. One example are VS code breakpoints in splitted codebases. |
Seems like we can autogenerate a relative path to the source directory rather than needing an extra option. Is there ever a usecase to pass it in manually? I think it would be something like |
@devongovett indeed, i did not know about the But i can also think of a usecase for setting the sourceRoot option manually to your network adress for when using remote debug for smartphones/TVs/web-devices. But this is more of a edgecase since normally your local browser should resolve the remote debugging information. |
|
Example: We bundle Sourcegraph extensions with Parcel, and all extensions typically have an The way to solve this if you only use source maps in local dev would be to supply a We also want to publish source maps in production, so we would actually set it to our raw API Another use case for setting Please add a |
See the source map spec:
|
Another thing is that Note how the tree starts at Spec reference:
|
@felixfbecker Please open a new issue with your comment, otherwise this will be forgotten. |
No description provided.