Skip to content

Commit e00c8a9

Browse files
committed
Try to remove dependency
1 parent 211f51c commit e00c8a9

File tree

3 files changed

+2
-6
lines changed

3 files changed

+2
-6
lines changed

human-formatter/index.js

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
11
import { once } from 'node:events'
22
import os from 'node:os'
33
import { Transform } from 'node:stream'
4+
import { stripVTControlCharacters } from 'node:util'
45
import pico from 'picocolors'
56
import pino from 'pino'
67
import abstractTransport from 'pino-abstract-transport'
7-
import stripAnsi from 'strip-ansi'
88

99
import { mulberry32, onceXmur3 } from './utils.js'
1010

@@ -50,7 +50,7 @@ function formatNow() {
5050
}
5151

5252
function rightPag(str, length) {
53-
let add = length - stripAnsi(str).length
53+
let add = length - stripVTControlCharacters(str).length
5454
for (let i = 0; i < add; i++) str += ' '
5555
return str
5656
}

package.json

-1
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,6 @@
4343
"pino": "9.5.0",
4444
"pino-abstract-transport": "^2.0.0",
4545
"semver": "^7.6.3",
46-
"strip-ansi": "^7.1.0",
4746
"tinyglobby": "^0.2.9",
4847
"url-pattern": "^1.0.3",
4948
"ws": "^8.18.0"

pnpm-lock.yaml

-3
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)