Seeing many typescript errors after cloning, "npm install" and "npm start"
Opened this issue · 1 comments
BoiseBaked commented
A few examples.
../async_pipe.d.ts(39,38): error TS2304: Cannot find name 'Promise'.
../index.d.ts(47,36): error TS2304: Cannot find name 'Iterable'.
../index.d.ts(1479,36): error TS2339: Property 'for' does not exist on type 'SymbolConstructor'.
BoiseBaked commented
Answering my question:
Let me add a little more detail to @milesaylward answer. You add "lib" : ["es2015", "es2015.iterable", "dom"] as an entry to the "compilerOptions": property found in the tsconfig.json file. E.g.
{
"compilerOptions": {
"target": "es5",
... // skipping entries here
"suppressImplicitAnyIndexErrors": true, // Don't forget to add the comma here.
"lib" : ["es2015", "es2015.iterable", "dom"]
}
}
Again, I have no idea why this works. If someone can explain what the problem was and how the "lib" compile option fixed the issue - please, please do.
Many thanks in advanced.