Skip to content

Commit d3604a9

Browse files
committed
Update README.md
1 parent dfe1e16 commit d3604a9

File tree

1 file changed

+14
-9
lines changed

1 file changed

+14
-9
lines changed

README.md

Lines changed: 14 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -33,12 +33,12 @@ Custom text color [colors-cli](https://github.com/jaywcjlove/colors-cli)
3333

3434
```js
3535
const color = require('colors-cli/toxic');
36-
const loading = require('loading-cli');
36+
const loading = require('loading-cli');
3737

3838
const load = loading("loading text!!".blue).start();
3939
// stop
4040
setTimeout(function(){
41-
load.stop()
41+
load.stop()
4242
},3000)
4343
```
4444

@@ -50,11 +50,11 @@ setTimeout(function(){
5050

5151
```js
5252
load({
53-
"text":"loading text!!",
54-
"color":"yellow",
55-
"interval":100,
56-
"stream": process.stdout,
57-
"frames":["", "", "", ""]
53+
"text":"loading text!!",
54+
"color":"yellow",
55+
"interval":100,
56+
"stream": process.stdout,
57+
"frames":["", "", "", ""]
5858
})
5959
```
6060

@@ -84,10 +84,8 @@ Values:`black` `red` `green` `yellow` `blue` `magenta` `cyan` `white` `gray`
8484
["🕐 ", "🕑 ", "🕒 ", "🕓 ", "🕔 ", "🕕 ", "🕖 ", "🕗 ", "🕘 ", "🕙 ", "🕚 "]
8585
```
8686

87-
8887
# Instance
8988

90-
9189
## .start([text])
9290

9391
Start the spinner. Returns the instance.
@@ -124,6 +122,13 @@ Manually render a new frame. Returns the instance.
124122

125123
Get a new frame.
126124

125+
```js
126+
const loading = require('loading-cli');
127+
const load = loading("loading text!!");
128+
load.frame(["", "", "", ""]);
129+
load.start();
130+
```
131+
127132
## .text
128133

129134
Change the text.

0 commit comments

Comments
 (0)