try like this: var text = "Hello World" JSON.stringify(text); ......... ........
On Tue, Mar 5, 2013 at 4:22 AM, Jon Craig <[email protected]>wrote: > I had the same issue. Discovered it was necessary to replace \r with > it's equivalent code \033[0G > If I had a buffer called data: > process.stdout.write(String(data).replace(/\r/g, '\033[0G')); > > -Jon Craig > > On Sunday, July 8, 2012 3:58:36 PM UTC-7, Alan Gutierrez wrote: >> >> I'd like to get animated progress working on Windows. >> >> baz.pl >> >> print "Hello\rW\r\n"; >> >> baz.js >> >> process.stdout.write('Hello\**rW\r\n'); >> >> console >> >> PS C:\git\proof> perl baz.pl >> WPS C:\git\proof> node .\baz.js >> Hello >> W >> PS C:\git\proof> >> >> I can find many sources on the Google that say that printing '\r' without >> '\n' >> to the Windows console (in this case PowerShell) will allow you to >> overwrite the >> line. >> >> -- >> Alan Gutierrez - http://twitter.com/bigeasy - http://github.com/bigeasy >> > -- > -- > Job Board: http://jobs.nodejs.org/ > Posting guidelines: > https://github.com/joyent/node/wiki/Mailing-List-Posting-Guidelines > You received this message because you are subscribed to the Google > Groups "nodejs" group. > To post to this group, send email to [email protected] > To unsubscribe from this group, send email to > [email protected] > For more options, visit this group at > http://groups.google.com/group/nodejs?hl=en?hl=en > > --- > You received this message because you are subscribed to the Google Groups > "nodejs" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to [email protected]. > For more options, visit https://groups.google.com/groups/opt_out. > > > -- Thanks, N. Srividhya. -- -- Job Board: http://jobs.nodejs.org/ Posting guidelines: https://github.com/joyent/node/wiki/Mailing-List-Posting-Guidelines You received this message because you are subscribed to the Google Groups "nodejs" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/nodejs?hl=en?hl=en --- You received this message because you are subscribed to the Google Groups "nodejs" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. For more options, visit https://groups.google.com/groups/opt_out.
