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

If there's a sourcemap for a file, mention the original line that causes the error #179

Open
jtomaszewski opened this issue Apr 7, 2023 · 1 comment

Comments

@jtomaszewski
Copy link

jtomaszewski commented Apr 7, 2023

Currently if I run es-check for a bundled/minified filed, it's a bit hard to tell which exact line of code (and which related library/file) causes the error. See screen below.

image

Instead, we could consume sourcemap (if there's one located in the file or next to it, e.g. a.js and a.js.map) with https://www.npmjs.com/package/source-map#new-sourcemapconsumerrawsourcemap , and then improve the es-check error message, by saying what's the original line that causes the error.

What do you think? Would you be open to such a code contribution?

@yowainwright
Copy link
Owner

@jtomaszewski I'm open to it! Thanks for this consideration!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants