-
Notifications
You must be signed in to change notification settings - Fork 12.5k
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
Forbid simultaneous noEmit
and incremental
#32882
Comments
Should we just roll this up into the other bug? |
Maybe? That one had opinions like "we should emit the bundle info path if a path is expressly given" - I'd just like to see an error if these two options are simultaneously specified right now, as it definitely doesn't do what you want. |
#33883 reverted the fix so this needs to be re opened |
I am not sure if we want to do this or not.. Given that older vs versions will still use |
cc: @RyanCavanaugh @DanielRosenwasser @uniqueiniquity @amcasey @minestarks to chime in what we should do here.. |
I frequently get confused about how this works (so @uniqueiniquity can correct me), but I think the msbuild code that passes those flags is rev'd with the compiler so there's no danger of running a new compiler (i.e. one that will warn/error) with an old build task/target (i.e. one that will trigger the warning/error). |
Thanks.. Will add this fix then |
…flict with --noEmit flag Since TS v3.8.2 the `--noEmit` flag cannot be used in conjuction with the `incremental` compiler option. microsoft/TypeScript#32882 We currently use the `--noEmit` flag to quickly run a type check on pre-commit and the `incremental` option for all our TS to JS compilation. I'd like to maintain this setup so that we do not have to compile code on commit, nor slow down builds by forcing them to run from scratch each time. To do this I have removed the incremental flag from the root TS config and appended the flag to each `tsc` script specified by each package.
noEmit
stops us from emitting any files (both bundle info and declarations).incremental
needs both of those. When both are set together today, all it does is force on declaration emit and then discard all the extra work done. As such, using the two together should trigger an error.Related: #30661
The text was updated successfully, but these errors were encountered: