MCPcopy Create free account
hub / github.com/npkgz/cli-progress / write

Method write

lib/terminal.js:123–130  ·  view source on GitHub ↗
(s, rawWrite=false)

Source from the content-addressed store, hash-verified

121 // write content to output stream
122 // @TODO use string-width to strip length
123 write(s, rawWrite=false){
124 // line wrapping enabled ? trim output
125 if (this.linewrap === true && rawWrite === false){
126 this.stream.write(s.substr(0, this.getWidth()));
127 }else{
128 this.stream.write(s);
129 }
130 }
131
132 // control line wrapping
133 lineWrapping(enabled){

Callers 7

updateMethod · 0.80
cursorSaveMethod · 0.80
cursorRestoreMethod · 0.80
cursorMethod · 0.80
newlineMethod · 0.80
lineWrappingMethod · 0.80
renderMethod · 0.80

Calls 1

getWidthMethod · 0.95

Tested by

no test coverage detected