mirror of
https://github.com/nuxt/nuxt.git
synced 2024-11-27 08:02:01 +00:00
fix: avoid pretty-error mutating traces
This commit is contained in:
parent
8868a4e8f4
commit
61232a61e6
@ -1,21 +1,7 @@
|
||||
const PrettyError = require('pretty-error')
|
||||
|
||||
// Start default instance
|
||||
const pe = PrettyError.start()
|
||||
|
||||
// Configure prettyError instance
|
||||
pe.skipPackage('regenerator-runtime')
|
||||
pe.skipPackage('babel-runtime')
|
||||
pe.skipPackage('core-js')
|
||||
|
||||
// Skip node internals
|
||||
pe.skip((traceLine, lineNumber) => {
|
||||
if (!traceLine.file) {
|
||||
return true
|
||||
}
|
||||
})
|
||||
|
||||
pe.skipNodeFiles()
|
||||
const pe = new PrettyError()
|
||||
|
||||
// Console error unhandled promises
|
||||
process.on('unhandledRejection', function (err) {
|
||||
|
Loading…
Reference in New Issue
Block a user