IssueRaiser

Configure from package.json

## Search Terms package.json, config, configuration, tsconfig ## Suggestion Allow `package.json` as an alternate source for `tsconfig.json` options. To be clear, I am requesting that you please re-evaluate #6590 - it has been 2 years since that issue was posted, so interests may have changed and I believe this feature holds good value. ### UPDATE: 2022-04-28 **Please vote how you would like to see this feature implemented here:** https://github.com/microsoft/TypeScript/issues/32830#issuecomment-1112372061 ## Use Cases > What do you want to use this for? Provide a broader configuration support and decluttering the project root of configuration files that can easily be moved to `package.json`. > What shortcomings exist with current approaches? Some users prefer to store their all their configuration files in 1 larger file. Right now, that is not an option. ## Examples Example of what the `package.json` would look like. ``` { "name": "example", "version": "1.0.0", "description": "This is an example", "license": "MIT", "tsconfig": { "compilerOptions": { "module": "commonjs", "moduleResolution": "node", "outDir": ".build", "pretty": true, "rootDir": "./", "sourceMap": true, "target": "ES5", "strict": true }, "exclude": [ "node_modules" ], "include": [ "index.ts", "src/**/*" ] } } ``` ## Checklist My suggestion meets these guidelines: * ✅ This wouldn't be a breaking change in existing TypeScript/JavaScript code * ✅ Th

Posted by ProjectCleverWeb on Aug 12, 2019, 11:16 PM

Tags

Related issues

Raise real-world problems, find people facing the same issue, and discuss solutions.3,500 issues0 comments

support (Software)

Configure from package.json

ProjectCleverWebAug 12, 2019, 11:16 PM

## Search Terms package.json, config, configuration, tsconfig ## Suggestion Allow `package.json` as an alternate source for `tsconfig.json` options. To be clear, I am requesting that you please re-evaluate #6590 - it has been 2 years since that issue was posted, so interests may have changed and I believe this feature holds good value. ### UPDATE: 2022-04-28 **Please vote how you would like to see this feature implemented here:** https://github.com/microsoft/TypeScript/issues/32830#issuecomment-1112372061 ## Use Cases > What do you want to use this for? Provide a broader configuration support and decluttering the project root of configuration files that can easily be moved to `package.json`. > What shortcomings exist with current approaches? Some users prefer to store their all their configuration files in 1 larger file. Right now, that is not an option. ## Examples Example of what the `package.json` would look like. ``` { "name": "example", "version": "1.0.0", "description": "This is an example", "license": "MIT", "tsconfig": { "compilerOptions": { "module": "commonjs", "moduleResolution": "node", "outDir": ".build", "pretty": true, "rootDir": "./", "sourceMap": true, "target": "ES5", "strict": true }, "exclude": [ "node_modules" ], "include": [ "index.ts", "src/**/*" ] } } ``` ## Checklist My suggestion meets these guidelines: * ✅ This wouldn't be a breaking change in existing TypeScript/JavaScript code * ✅ Th

Comments (0)

No comments yet. Start the discussion.

Comment on this issue