Skip to content

Commit 40143b7

Browse files
committed
doc: npm package chalk
1 parent 0555ce8 commit 40143b7

File tree

2 files changed

+16
-2
lines changed

2 files changed

+16
-2
lines changed
107 KB
Loading

docs/start/npm.md

+16-2
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ sidebarDepth: 0
99
* [Inquirer](https://github.com/SBoudrias/Inquirer.js):A collection of common interactive command line user interfaces。
1010
* [handlebars](https://github.com/wycats/handlebars.js):一个 javascript 语以模版库。
1111
* [metalsmith](https://github.com/segmentio/metalsmith);An extremely simple, pluggable static site generator。
12-
* [chalk](https://github.com/chalk/chalk)
12+
* [chalk](https://github.com/chalk/chalk):Terminal string styling done right。
1313
* [download-git-repo](https://github.com/flipxfx/download-git-repo)
1414
* [consolidate](https://github.com/tj/consolidate.js)
1515

@@ -125,4 +125,18 @@ function plugin(opts){
125125
};
126126
}
127127
```
128-
关于 `metalsmith` 的更多介绍以及语法可查看[详细文档](https://metalsmith.io/)
128+
关于 `metalsmith` 的更多介绍以及语法可查看[详细文档](https://metalsmith.io/)
129+
130+
# chalk
131+
132+
`chalk` 是用于修改控制台字符串的样式,包括字体样式(加粗),颜色以及背景颜色等。
133+
134+
<img :src="$withBase('/assets/install-img02.png')">
135+
136+
使用比较简单:
137+
138+
``` javascript
139+
const chalk = require('chalk');
140+
console.log(chalk.blue('Hello world!'));
141+
```
142+
更多的用法以及 `API` 可查看[详细文档](https://github.com/chalk/chalk)

0 commit comments

Comments
 (0)