Skip to content
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

Feature Request: Try to use original file(s) if sourcesContent is unavailable #17

Open
ehoogeveen-medweb opened this issue Feb 20, 2023 · 2 comments · May be fixed by #21
Open

Feature Request: Try to use original file(s) if sourcesContent is unavailable #17

ehoogeveen-medweb opened this issue Feb 20, 2023 · 2 comments · May be fixed by #21
Labels
enhancement New feature or request

Comments

@ehoogeveen-medweb
Copy link

Hi, we strip sourcesContent from our source maps to reduce bloat and prevent accidentally leaking our unminified source code. Unfortunately when I try to visualize such a source map with this extension, it looks something like this:
image
The offsets are correct, but the text is missing. Could you try to read the original file(s) if sourcesContent is unavailable? Of course, if they are missing then there isn't much you can do, but in my case the files are accessible.

@cncolder
Copy link
Owner

cncolder commented Apr 5, 2023

Hmm... How did you remove the sourcesContent?

  1. Completely remove sourcesContent field.
  2. "sourcesContent": []
  3. "sourcesContent": [null, null]

If I understand right, you want to fill in the nullish item of sourcesContent by the content of sources?

@ehoogeveen-medweb
Copy link
Author

We completely remove the field, but I guess the other options make sense too. Yes, I'd like it if the extension could supplement missing sourcesContent by looking up the files in sources and inserting their contents.

@jhandley jhandley linked a pull request Apr 8, 2023 that will close this issue
@cncolder cncolder added the enhancement New feature or request label May 4, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants