Commit e6685d66 authored by 楊慶堂's avatar 楊慶堂
parent 6aca9028
/**
* npm install source-map
* node ParseMap.js
*/
var sourceMap = require('source-map');
var fs = require('fs');
var rawSourceMap = JSON.parse(fs.readFileSync('test.bundle.map', 'utf8'));
const whatever = sourceMap.SourceMapConsumer.with(rawSourceMap, null, consumer => {
console.log(consumer.originalPositionFor({
line: 577,
column: 2554
}));
});
{
"requires": true,
"lockfileVersion": 1,
"dependencies": {
"source-map": {
"version": "0.7.2",
"resolved": "https://registry.npmjs.org/source-map/-/source-map-0.7.2.tgz",
"integrity": "sha512-NDJB/R2BS7YJG0tP9SbE4DKwKj1idLT5RJqfVYZ7dreFX7wulZT3xxVhbYKrQo9n0JkRptl51TrX/5VK3HodMA=="
}
}
}
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment