Skip to content

Commit

Permalink
fix: raise unhandled rejection on child process as uncaught exception
Browse files Browse the repository at this point in the history
ref: #5
  • Loading branch information
mihar-22 committed May 18, 2020
1 parent 0d82b6a commit ae64409
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@
"@types/jest": "^25.1.2",
"doctoc": "^1.4.0",
"jest": "^25.1.0",
"node-sass": "^4.13.1",
"node-sass": "^4.14.1",
"standard": "^14.3.1",
"standard-version": "^7.1.0",
"svelte": "^3.18.2",
Expand Down
2 changes: 1 addition & 1 deletion src/transformer.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ const transformer = (options = {}) => (source, filename) => {

if (preprocess) {
const preprocessor = require.resolve('./preprocess.js')
processed = execSync(`node ${preprocessor}`, {
processed = execSync(`node --unhandled-rejections=strict --abort-on-uncaught-exception ${preprocessor}`, {
env: { PATH: process.env.PATH, source, filename }
}).toString()
}
Expand Down

0 comments on commit ae64409

Please sign in to comment.