Package Exports
- stack-source-map
- stack-source-map/register
This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (stack-source-map) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.
Readme
Stack-source-map
Attamp to make error stack works with source-map in browser, only Chrome supportted yet.
The code mostly from evanw/node-source-map-support, but simplified to works with browser only and fixed to support all source map mode of webpack
Basically, it's some kind hack of v8 message.js
Works with babel and webpack 😃
Install
npm install stack-source-map
Usage
require('stack-source-map')()
entry for webpack
var entry = [
'stack-source-map/register'
// other entries
...
]
Use standalond file
Include file stacksourmap.js
in your page, and add one line code:
StackSourceMap()
API
stackSourceMap([option])
option.empty
empty cache between operations if true, default false
Test babel with webpack
npm install
node server
open http://localhost:8080/bundle
License
MIT