Skip to content

Commit 8ab7046

Browse files
committed
replace chalk with picocolors
1 parent 503f8c5 commit 8ab7046

File tree

3 files changed

+6
-6
lines changed

3 files changed

+6
-6
lines changed

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -47,8 +47,8 @@
4747
"typings/index.flow.js"
4848
],
4949
"dependencies": {
50-
"chalk": "^4.1.2",
5150
"jest-matcher-utils": "^30.0.5",
51+
"picocolors": "^1.1.1",
5252
"pretty-format": "^30.0.5",
5353
"redent": "^3.0.0"
5454
},

src/helpers/logger.ts

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,12 @@
1-
import chalk from 'chalk';
21
import * as nodeConsole from 'console';
2+
import pc from 'picocolors';
33
import redent from 'redent';
44
import * as nodeUtil from 'util';
55

66
export const logger = {
77
debug(message: unknown, ...args: unknown[]) {
88
const output = formatMessage('●', message, ...args);
9-
nodeConsole.debug(chalk.dim(output));
9+
nodeConsole.debug(pc.dim(output));
1010
},
1111

1212
info(message: unknown, ...args: unknown[]) {
@@ -16,12 +16,12 @@ export const logger = {
1616

1717
warn(message: unknown, ...args: unknown[]) {
1818
const output = formatMessage('▲', message, ...args);
19-
nodeConsole.warn(chalk.yellow(output));
19+
nodeConsole.warn(pc.yellow(output));
2020
},
2121

2222
error(message: unknown, ...args: unknown[]) {
2323
const output = formatMessage('■', message, ...args);
24-
nodeConsole.error(chalk.red(output));
24+
nodeConsole.error(pc.red(output));
2525
},
2626
};
2727

yarn.lock

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2990,13 +2990,13 @@ __metadata:
29902990
"@types/react-test-renderer": "npm:^19.1.0"
29912991
babel-jest: "npm:^30.0.5"
29922992
babel-plugin-module-resolver: "npm:^5.0.2"
2993-
chalk: "npm:^4.1.2"
29942993
del-cli: "npm:^6.0.0"
29952994
eslint: "npm:^9.33.0"
29962995
eslint-plugin-simple-import-sort: "npm:^12.1.1"
29972996
flow-bin: "npm:~0.170.0"
29982997
jest: "npm:^30.0.5"
29992998
jest-matcher-utils: "npm:^30.0.5"
2999+
picocolors: "npm:^1.1.1"
30003000
prettier: "npm:^3.6.2"
30013001
pretty-format: "npm:^30.0.5"
30023002
react: "npm:19.1.0"

0 commit comments

Comments
 (0)