Description
Current Deno will remap stack traces on files that have been compiled by Deno, as Deno caches both the original file and the emitted map, and loads those from the cache. When consuming JavaScript with source maps from other sources (like already compiled code) Deno does not handle the source map and ignore source map pragma included in files.
Deno should support both external source maps and inline source maps when fetching modules and store any source maps in the cache to be used when remapping stack traces.
This will have the side-effect of supporting the generation of source maps for bundles generated by deno bundle
.
One consideration is that source maps optionally can include the original sources. If they do, then when emitting an error, the original source line is available, but if they don't, we would not be able to log-out/resolve that original source line.