@@ -33,12 +33,12 @@ Custom text color [colors-cli](https://github.com/jaywcjlove/colors-cli)
33
33
34
34
``` js
35
35
const color = require (' colors-cli/toxic' );
36
- const loading = require (' loading-cli' );
36
+ const loading = require (' loading-cli' );
37
37
38
38
const load = loading (" loading text!!" .blue ).start ();
39
39
// stop
40
40
setTimeout (function (){
41
- load .stop ()
41
+ load .stop ()
42
42
},3000 )
43
43
```
44
44
@@ -50,11 +50,11 @@ setTimeout(function(){
50
50
51
51
``` js
52
52
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" : [" ◰" , " ◳" , " ◲" , " ◱" ]
58
58
})
59
59
```
60
60
@@ -84,10 +84,8 @@ Values:`black` `red` `green` `yellow` `blue` `magenta` `cyan` `white` `gray`
84
84
[" 🕐 " , " 🕑 " , " 🕒 " , " 🕓 " , " 🕔 " , " 🕕 " , " 🕖 " , " 🕗 " , " 🕘 " , " 🕙 " , " 🕚 " ]
85
85
```
86
86
87
-
88
87
# Instance
89
88
90
-
91
89
## .start([ text] )
92
90
93
91
Start the spinner. Returns the instance.
@@ -124,6 +122,13 @@ Manually render a new frame. Returns the instance.
124
122
125
123
Get a new frame.
126
124
125
+ ``` js
126
+ const loading = require (' loading-cli' );
127
+ const load = loading (" loading text!!" );
128
+ load .frame ([" ◰" , " ◳" , " ◲" , " ◱" ]);
129
+ load .start ();
130
+ ```
131
+
127
132
## .text
128
133
129
134
Change the text.
0 commit comments