microsoft / microsoft/TypeScript
`references` are not inherited in `tsconfig.json`
@RyanCavanaugh ci sta già lavorando.
Dal 14/12/2018.
- Lingua principale
- Go
- Stelle
- 111k
- Fork
- 14.3k
- Merge medio
- 2g 4h
- PR unite (30g)
- 132
Descrizione
TypeScript Version: 3.1.0-dev.20180914
Search Terms: tsconfig.json extends references inheritance
It seems that the references key is not inherited via the extends mechanism, which surprised me because the handbook doesn't mention anything special about it.
Demo:
tsconfig.base.json:
{
"references": [
{ "path": "./some/other/project" }
],
"compilerOptions": {
"declaration": true,
"composite": true
}
}
tsconfig.doesnt-work.json:
{
"extends": "./tsconfig.base.json"
}
Building tsconfig.doesnt-work.json doesn't build the reference:
$ tsc -b -f -d tsconfig.doesnt-work.json
[11:12:13] A non-dry build would build project 'C:/demo/tsconfig.doesnt-work.json'
tsconfig.works-but-duplicates-references.json:
{
"extends": "./tsconfig.base.json",
"references": [
{ "path": "./some/other/project" }
],
}
This is a correct build but I had to duplicate the references key:
$ tsc -b -f -d tsconfig.works-but-duplicates-references.json
[11:12:13] A non-dry build would build project 'C:/demo/tsconfig.works-but-duplicates-references.json'
[11:12:13] A non-dry build would build project 'C:/demo/some/other/project/tsconfig.json'
Guida per i contributori
Apri la guida per i contributori
Come iniziare
- Leggi tutta la issue e poi la guida ai contributi del progetto.
- Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
- Fai un fork del repository e lavora su un branch.
- Apri una pull request che faccia riferimento al numero della issue.
Valutazione
Questa issue non è ancora stata valutata.