@drill4j/js-parser v0.4.0
AST-parser (drill4js-cli utility)
Production build
Set
"sourceMap": false,in tsconfig.jsonTODO: add separate build config
Run
npm run buildRelease
To release a new package version:
- Bump version in
package.jsonmanually - Run commands from Production build section
Run
npm publish --dry-run:ensure that only necessary files are listed in package preview
ensure that
npm-shrinkwrap.jsondoes not include development dependencies
Run
npm publishornpm publish --tag beta
Development build & debug
Install development dependencies
rm -rf node_modules npm iSet
"sourceMap": true,in tsconfig.jsonRun webpack development server
npm run devAttach debugger to the process started with
npm run devVScode:
- Run
Debug on fixtureslaunch configuration - Edit configuration to debug on different files
Other IDEs:
- Attach debugger of your choice to the running process, use .vscode/launch.json
Debug on fixturesconfiguration as the example
- Run
What is WASM module in `src/third-party/chromehash"
This modules provides algorithm that V8 uses internally to uniquely identify each script
brief explanation:
js-parserutilizes it to get hash for each bundle fileHere, terms script and bundle file are used interchangeably. Both indicate the javascript files executed in browser.
V8 attaches the exact same hash for each script in Debugger.scriptParsed event
js-agentmatches hashes provided by V8 with hashes calculated byjs-parserto map coverage to the correct bundle fileThen bundle coverage is mapped to original sources (e.g. TypeScript files). For further details see
js-agentrepository
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
4 years ago
4 years ago