Loading topic
tsconfig.json is the right starting point for almost every TypeScript project. It stops being the right tool when a repository grows into several packages with different needs. This chapter explains the specific costs of staying with one config, what project references change, and when yo7 min readtsconfig.json, know what target, strict, module, and outDir do, and can run tsc from a terminal. You do not need project references yet. This chapter prepares the ground for them.6 min readtsconfig.json, know what target, strict, outDir and rootDir do, and have run tsc from the command line. It also assumes you have seen the shared tsconfig.base.json from the previous chapter.6 min readtsconfig.json, know what target, strict, and outDir do, and have run tsc from the command line. It also assumes you have seen the composite option introduced in the previous chapter. Here we look at the files a composite project writes to disk and why 5 min readtsconfig.json files, and output folders so project references work without surprises. It assumes you can read a tsconfig.json, know what rootDir and outDir do, and have seen the composite option and the references field from the earlier cha6 min readtsconfig.json does and can run tsc. It also assumes you have read the earlier chapters on extends, composite, and declaration output. Here you will connect projects with the references field and see what the compiler does with it.5 min readcomposite, declaration outputs, and the references field. You should be comfortable with ES module imports and with how NodeNext resolution treats file extensions.5 min readcore and app projects from the earlier chapters. core is a composite project, and app references it. You should also be comfortable running tsc and reading tsconfig.json options. Here you will learn what a .tsbuildinfo file stores, how tsc uses it to5 min readtsc --build command (also written tsc -b). It assumes you can read a tsconfig.json, know what outDir and declaration do, and have a repository where packages/app references packages/core, both with composite enabled. Earlier chapters set up that la5 min readcomposite: true, core is listed in app's references, and a shared tsconfig.base.json sits at the repository root. It also assumes you can run tsc --build.7 min readtsc --build decides the order in which to build projects, and why the references graph must not contain a cycle. It assumes you can write a composite project with references, as in the earlier chapters, and that you have run tsc --build at least once.7 min readcore project and an app project that lists core in references, plus a solution-style root tsconfig.json. It also assumes you use an editor that talks to TypeScript's language server, such as VS Code. Here you will5 min readtsc --build on a continuous integration (CI) server. It assumes you can already build the core and app projects from earlier chapters, that your root tsconfig.json is solution-style, and that you know what a .tsbuildinfo file is. The examples use GitHub Actions,6 min readextends, a composite project, the references field, and tsc --build. Most failures in a references setup come from a small set of causes. Once you can read the error code, t6 min read