Closed
Description
At Google, we keep all dependency information in source files, and generate the tsconfig.json
file in the build tooling (https://github.com/bazelbuild/rules_typescript/blob/master/internal/common/tsconfig.bzl)
In order to generate the libs[]
, we currently use some special one-off comment syntax, which is not understood by editors or other tools. It would be much nicer to specify required TS libs in the source file, the same way as for types[]
.
Currently the behavior is not symmetric:
dep | source file | tsconfig.json |
---|---|---|
types | /// <reference types="node"/> |
"types": [] |
libs | ??? | "libs": [] |
We'd like to be able to do /// <reference libs="es2015.collection" />
/cc @evmar