paperdave / various

Various libraries and applications related to TypeScript. Everything is contained in a monorepo to improve productivity and reduce boilerplate.
MIT License
31 stars 3 forks source link

logger: shorten paths if possible #19

Closed paperdave closed 1 year ago

paperdave commented 2 years ago

What package(s) does this bug target?

@paperdave/logger

Describe the bug and how to reproduce it.

formatStackTrace either uses a short built in name for stuff like node:fs but if it's a js file, it'l print the whole path. we should do some detection of a package.json or .git, or going off the npm_package_json env var (yarn and pnpm do not set this var, but bun and npm do)