20.8 Extending tsconfig: Shared Base Configurations
Right, so you’ve got more than one project. And you’re not a masochist. You don’t want to copy-paste the same 50 lines of tsconfig.json into every single frontend app, library, and random script folder. This is where extends swoops in to save you from your own maintenance nightmare. It’s the closest thing we have to configuration inheritance, and it’s glorious. The concept is simple: you define a base tsconfig.json file with all your shared, common settings. Then, in your individual project configs, you point to that base file and add the project-specific tweaks. TypeScript will effectively merge the two. It’s like a parent setting the house rules (“no anys in this house, young man!”), and the child project adding its own exceptions (“but I need "moduleResolution": "nodenext" for this one thing!”).