TypeScript · Compiler and project settings

include / exclude

Selects which files the project type-checks.

Syntax
"include": ["app/**/*.ts"]

Example

Example
{
  "include": ["app/**/*.ts", "server/**/*.ts"],
  "exclude": ["node_modules"]
}

More in this group

exactOptionalPropertyTypes lib moduleResolution noEmit noUncheckedIndexedAccess paths skipLibCheck strict

Learn this in the course

Reference pages are the quick answer. The course explains the why, shows the full example and ends with a challenge.

Open the course