TypeScript · Backwards Compatibility
importsNotUsedAsValues
Specify emit/checking behavior for imports that are only used for types.
Syntax
"importsNotUsedAsValues": "remove"Example
Example
{
"compilerOptions": {
"importsNotUsedAsValues": "remove"
}
}More in this group
Learn this in the course
Reference pages are the quick answer. The course explains the why, shows the full example and ends with a challenge.