Urara-Blog/node_modules/.pnpm-store/v3/files/c5/1f565860b5f12e65733ace6e2f2f71abf6e273a2a7ceafa07e9cd1da282522b17ae459f115d1b94c5d61a84d6b8798cc5b3c1e8cc3f33b5cc2e9c10fcfb488
2022-08-14 01:14:53 +08:00

16 lines
262 B
Text

import { sep } from 'path'
export function parseStack (stack) {
const cwd = process.cwd() + sep
const lines = stack
.split('\n')
.splice(1)
.map(l => l
.trim()
.replace('file://', '')
.replace(cwd, '')
)
return lines
}