lib/prepareError.js
function prepareStack(stack) {
	let lines = stack.split('\n').slice(1)

	if (lines.length > 500) {
		// Stack too big, probably this is caused by stack overflow
		// Remove middle values
		let skipped = lines.length - 500,
			top = lines.slice(0, 250),
			bottom = lines.slice(-250)
		lines = top.concat('--- skipped ' + skipped + ' frames ---', bottom)
	}

	return lines.map(line => line.trim().replace(/^at /, '').replace(basePath, '.'))
}
function prepareStack(stack) {
	let lines = stack.split('\n').slice(1)

	if (lines.length > 500) {
		// Stack too big, probably this is caused by stack overflow
		// Remove middle values
		let skipped = lines.length - 500,
			top = lines.slice(0, 250),
			bottom = lines.slice(-250)
		lines = top.concat('--- skipped ' + skipped + ' frames ---', bottom)
	}

	return lines.map(line => line.trim().replace(/^at /, '').replace(basePath, '.'))
}
function prepareStack ( stack ) { let lines = stack . split ( '\n' ) . slice ( 1 ) if ( lines . length > 500 ) { // Stack too big, probably this is caused by stack overflow // Remove middle values let skipped = lines . length - 500 , top = lines . slice ( 0 , 250 ) , bottom = lines . slice ( - 250 ) lines = top . concat ( '--- skipped ' + skipped + ' frames ---' , bottom ) } return lines . map ( line => line . trim ( ) . replace ( / ^at  / , '' ) . replace ( basePath , '.' ) ) }
Split each stack frame and normalize paths
@param {string} stack
@returns {Array<string>}
@private
Split each stack frame and normalize paths