Closed
Description
Suggestion
With package-based paths now allowed within tsconfig extends clauses, we now have the opportunity to ship prescriptive base configs with our published package.
Use Cases
This could be useful for providing extra "defaults" for certain scenarios, like jsx
, js
, or a babel-y project, under paths like typescript/jsx
, typescript/js
and typescript/babel
.
Examples
We publish, eg, react/tsconfig.json
with contents:
{
"compilerOptions": {
"jsx": "react",
"esModuleInterop": true,
"allowSyntheticDefaultImports": true,
"target": "es5",
"module": "commonjs",
"sourceMap": true
}
}
so users can then write configs like:
{
"extends": "typescript/react",
"include": [ "src/**/*" ],
"compilerOnSave": true
}