Skip to content
GitLab
Explore
Projects
Groups
Snippets
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
Meta
create-react-app
Commits
801c2002
Commit
801c2002
authored
8 years ago
by
Dan Abramov
Browse files
Options
Download
Email Patches
Plain Diff
Tweak scroll sequences
parent
2dd105df
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
scripts/start.js
+5
-3
scripts/start.js
with
5 additions
and
3 deletions
+5
-3
scripts/start.js
+
5
-
3
View file @
801c2002
...
@@ -69,10 +69,12 @@ function formatMessage(message) {
...
@@ -69,10 +69,12 @@ function formatMessage(message) {
.
replace
(
'
./~/css-loader!./~/postcss-loader!
'
,
''
);
.
replace
(
'
./~/css-loader!./~/postcss-loader!
'
,
''
);
}
}
var
isFirstClear
=
true
;
function
clearConsole
()
{
function
clearConsole
()
{
// This seems to work best on Windows and other systems.
// On first run, clear completely so it doesn't show half screen on Windows.
// The intention is to clear the output so you can focus on most recent build.
// On next runs, use a different sequence that properly scrolls back.
process
.
stdout
.
write
(
'
\
x1bc
'
);
process
.
stdout
.
write
(
isFirstClear
?
'
\
x1bc
'
:
'
\
x1b[2J
\
x1b[0f
'
);
isFirstClear
=
false
;
}
}
function
setupCompiler
(
port
,
protocol
)
{
function
setupCompiler
(
port
,
protocol
)
{
...
...
This diff is collapsed.
Click to expand it.
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment
Menu
Explore
Projects
Groups
Snippets