How can I get the original line number and symbol from a sourcemap

ⅰ亾dé卋堺 提交于 2019-12-23 07:46:25

问题


I'm logging javascript errors from my site, but the files are minimized so I don't get meaningful line numbers. I do have source maps, however.

Is there a service, script, npm module, or anything that can help me "translate" the line numbers from the minified versions into something useful?


回答1:


I have found the answer using this npm module:

https://www.npmjs.org/package/source-map

Edit Feb 1st, 2015

Found the following project which handles this: https://github.com/epeli/source-map-peek



来源:https://stackoverflow.com/questions/25023178/how-can-i-get-the-original-line-number-and-symbol-from-a-sourcemap

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!