cleanup(web): migrate to picocolors (#28039)
This commit is contained in:
parent
0d50b13a25
commit
246494ae2d
@ -4,7 +4,15 @@
|
||||
"overrides": [
|
||||
{
|
||||
"files": ["*.ts", "*.tsx", "*.js", "*.jsx"],
|
||||
"rules": {}
|
||||
"rules": {
|
||||
"no-restricted-imports": [
|
||||
"error",
|
||||
{
|
||||
"name": "chalk",
|
||||
"message": "Please use `picocolors` in place of `chalk` for rendering terminal colors"
|
||||
}
|
||||
]
|
||||
}
|
||||
},
|
||||
{
|
||||
"files": ["**/*.ts"],
|
||||
|
||||
@ -31,9 +31,9 @@
|
||||
"migrations": "./migrations.json"
|
||||
},
|
||||
"dependencies": {
|
||||
"chalk": "^4.1.0",
|
||||
"detect-port": "^1.5.1",
|
||||
"http-server": "^14.1.0",
|
||||
"picocolors": "^1.1.0",
|
||||
"tslib": "^2.3.0",
|
||||
"@nx/devkit": "file:../devkit",
|
||||
"@nx/js": "file:../js"
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
import { execFileSync, fork } from 'child_process';
|
||||
import * as chalk from 'chalk';
|
||||
import * as pc from 'picocolors';
|
||||
import {
|
||||
ExecutorContext,
|
||||
output,
|
||||
@ -176,7 +176,7 @@ export default async function* fileServerExecutor(
|
||||
});
|
||||
} catch {
|
||||
throw new Error(
|
||||
`Build target failed: ${chalk.bold(options.buildTarget)}`
|
||||
`Build target failed: ${pc.bold(options.buildTarget)}`
|
||||
);
|
||||
} finally {
|
||||
process.env.NX_SERVE_STATIC_BUILD_RUNNING = undefined;
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user