From d726d2242a1c17b020224522bf4e7304bc8de4be Mon Sep 17 00:00:00 2001 From: Daniel Verejan Date: Tue, 9 Jan 2018 15:46:29 +0200 Subject: [PATCH] Update the string that clears the console. (#2071) * Update the string that clears the console. #1914 I've tested it with Windows 10 and 7, node versions from ~5.0.0 up to 7.7.0. Didn't managed to test it on 8 but it should be fine. * Update windows string Add windows specific string for clearing the console. --- packages/react-dev-utils/clearConsole.js | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/packages/react-dev-utils/clearConsole.js b/packages/react-dev-utils/clearConsole.js index 6e3b3c9cefe..cb02af89237 100644 --- a/packages/react-dev-utils/clearConsole.js +++ b/packages/react-dev-utils/clearConsole.js @@ -8,9 +8,7 @@ 'use strict'; function clearConsole() { - process.stdout.write( - process.platform === 'win32' ? '\x1Bc' : '\x1B[2J\x1B[3J\x1B[H' - ); + process.stdout.write(process.platform === 'win32' ? '\x1B[2J\x1B[0f' : '\x1B[2J\x1B[3J\x1B[H'); } module.exports = clearConsole;