From bffe7312504119bdc066e59459209b8cf09d4bca Mon Sep 17 00:00:00 2001 From: Kamontat Chantrachirathumrong <14089557+kamontat@users.noreply.github.com> Date: Thu, 17 Sep 2026 21:32:52 +0700 Subject: [PATCH] docs: tsconfig#extends have been support array since 2023 Updated the 'extends' property description to indicate it can accept a list of strings. Added example configurations for clarity. --- .../copy/en/options/extends.md | 21 ++++++++++++++++++- 1 file changed, 20 insertions(+), 1 deletion(-) diff --git a/packages/tsconfig-reference/copy/en/options/extends.md b/packages/tsconfig-reference/copy/en/options/extends.md index b29043def126..1e03c8fb0255 100644 --- a/packages/tsconfig-reference/copy/en/options/extends.md +++ b/packages/tsconfig-reference/copy/en/options/extends.md @@ -3,7 +3,7 @@ display: "Extends" oneline: "Specify one or more path or node module references to base configuration files from which settings are inherited." --- -The value of `extends` is a string which contains a path to another configuration file to inherit from. +The value of `extends` is a string or list of strings which contains a path to another configuration file to inherit from. The path may use Node.js style resolution. The configuration from the base file are loaded first, then overridden by those in the inheriting config file. All relative paths found in the configuration file will be resolved relative to the configuration file they originated in. @@ -26,6 +26,16 @@ Currently, the only top-level property that is excluded from inheritance is [`re } ``` +`configs/withJson.json`: + +```json tsconfig +{ + "compilerOptions": { + "resolveJsonModule": true + } +} +``` + `tsconfig.json`: ```json tsconfig @@ -35,6 +45,15 @@ Currently, the only top-level property that is excluded from inheritance is [`re } ``` +`tsconfig.custom.json`: + +```json tsconfig +{ + "extends": ["./configs/base", "./configs/withJson.json"], + "files": ["main.ts", "package.json"] +} +``` + `tsconfig.nostrictnull.json`: ```json tsconfig