Skip to content

react-dev-utils/clearConsole doesn't clear the console on windows #1914

New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Closed
DanielBadan opened this issue Mar 31, 2017 · 9 comments
Closed

react-dev-utils/clearConsole doesn't clear the console on windows #1914

DanielBadan opened this issue Mar 31, 2017 · 9 comments

Comments

@DanielBadan
Copy link
Contributor

Description

On windows the console is not cleared with \x1Bc char, it works though with \x1B[2J\x1B[3J\x1B[H but as I'm on windows it will never get to that.

Is there a compatibility issue that requires the win32 check?

What are you reporting?
Bug?

Expected behavior

Console should be cleared

Actual behavior

Console get's full with compilation logs

Environment

  • Windows 10
  • Node 7.8.0
  • npm 4.2.0
  • Git Bash 2.12.2
  • Latest CRA
@DanielBadan DanielBadan changed the title react-dev-utils/clearConsole doesn't clear the console react-dev-utils/clearConsole doesn't clear the console on windows Mar 31, 2017
@Timer
Copy link
Contributor

Timer commented Mar 31, 2017

Does the console clear but retain it's history? This is the intended behavior iirc.

@Timer
Copy link
Contributor

Timer commented Mar 31, 2017

See #611 and #794.

@gaearon
Copy link
Contributor

gaearon commented Mar 31, 2017

It would help to see the screenshots.
Also which console environment are you using?

@DanielBadan
Copy link
Contributor Author

2017-04-03_0933

Terminal Type: xterm-256color

@gaearon
Copy link
Contributor

gaearon commented Apr 3, 2017

How exactly are you launching the terminal? Imagine I have a clean Windows 10 installation. What do I need to do to reproduce this?

@DanielBadan
Copy link
Contributor Author

DanielBadan commented Apr 3, 2017

When you install GitBash, 2 new options are available in the right click menu. Right click in the explorer and Git Bash Here

@gaearon
Copy link
Contributor

gaearon commented Apr 4, 2017

Oh, I see. I'm not sure we can support the more exotic environments. We went through quite a few attempts to make it look right on OS X, Linux, and popular Windows environments (Cmd and PowerShell). Sorry 😞

@DanielBadan
Copy link
Contributor Author

It is probably a node problem to. Just tested with different versions of node and using Node v.7.5.0 and up and was getting the same result(console not cleaning) in Cmd, PowerShell and GitBash.

@gaearon
Copy link
Contributor

gaearon commented Apr 4, 2017

Interesting. If you can get it consistently reproducing with Cmd on Windows 10, we'll need to take a look.

DanielBadan pushed a commit to DanielBadan/create-react-app that referenced this issue May 3, 2017
facebook#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.
gaearon pushed a commit that referenced this issue Jan 9, 2018
* 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.
@Timer Timer closed this as completed Jan 12, 2018
@Timer Timer added this to the 1.0.18 milestone Jan 12, 2018
Pavek pushed a commit to Pavek/create-react-app that referenced this issue Jul 10, 2018
* Update the string that clears the console.

facebook#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.
@lock lock bot locked and limited conversation to collaborators Jan 20, 2019
# for free to subscribe to this conversation on GitHub. Already have an account? #.
Projects
None yet
Development

No branches or pull requests

3 participants