Control TSC's noEmit or emitDeclarationOnly when using composite projects
See original GitHub issuecreate-react-app
doesn’t work in composite typescript projects, because for composite projects emitDeclarationOnly
must be used instead of noEmit
(when using noEmit: true and composite: true typescript compiler throws an error). I suggest to add a check - if typescript project is composite-based, use emitDeclarationOnly
flag instead of noEmit
.
See https://github.com/microsoft/TypeScript/issues/36917 for more information.
Issue Analytics
- State:
- Created 4 years ago
- Reactions:16
- Comments:7
Top Results From Across the Web
Option 'noEmit' cannot be specified with option 'incremental'
So you should either remove noEmit: true or change it to emitDeclarationOnly: true . You can control the output folders using outDir and ......
Read more >Documentation - tsc CLI Options - TypeScript
Flag Type Default
‑‑allowJs boolean false
‑‑allowUmdGlobalAccess boolean false
‑‑allowUnreachableCode boolean
Read more >Understanding TypeScript Configuration Options
composite - tsBuildInfoFile - removeComments - noEmit - importHelpers ... By using it, you can structure your TypeScript project into smaller pieces.
Read more >Kent C. Dodds on Twitter: "Ok, here's the best I got at the ...
I have a project with a client and server directory. ... Tried the "Project References" feature but I don't think that works with...
Read more >TypeScript rules for Bazel - GitHub Pages
This can be used for a build with --noEmit , so that TypeScript is purely ... ts_project simply runs tsc --project , with...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
This is still a thing… I’m kinda getting annoyed by the fact, that some options are forced in such a way, without any explanation…
Options for incremental builds can look like this:
Adding support for the
incremental
option was previously proposed in #6785, but was closed due to the webpack plugin already using incremental builds, but I think that misses the point; it’s also useful to check types withtsc
without building, since it’s faster and allows to type check files that aren’t open in an editor.