-
-
Notifications
You must be signed in to change notification settings - Fork 591
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
fix: show a warning if serve and --watch
are used together
#2375
Conversation
Codecov Report
@@ Coverage Diff @@
## master #2375 +/- ##
==========================================
+ Coverage 70.52% 71.26% +0.74%
==========================================
Files 47 46 -1
Lines 2158 2158
Branches 563 570 +7
==========================================
+ Hits 1522 1538 +16
+ Misses 636 620 -16
Continue to review full report at Codecov.
|
packages/serve/src/index.ts
Outdated
// warn user about using '--watch' with serve | ||
if (optionName === 'watch') { | ||
logger.warn("Do not use '--watch' with 'serve'. It has no effect."); | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It should be inside serve
command, because only serve
command know what it is unnecessary
Ideally we should:
I think it is the best DX |
be1456b
to
595b0ac
Compare
What kind of change does this PR introduce?
fix
Did you add tests for your changes?
yes
If relevant, did you update the documentation?
no
Summary
fixes #2370
show a warning if
serve
and--watch
are used togetherDoes this PR introduce a breaking change?
No
Other information
I will work on removing
--watch
&--no-watch
options fromserve
help output in next PR.