We just upgraded our application from Angular 4 to Angular 7. The site is up and running with ng serve locally and also working fine in multiple environments(ETE, QA, Pilot etc) with builds against each environment without the below fix. But when we run the unit tests we are getting the below error,
error TS2339: Property 'flatMap' does not exist on type 'any[] jasmine
Found a fix by adding "esnext.array" inside the tsconfig.json file under lib as pointed out in the question Typescript flatMap, flat, flatten doesn't exist on type any[].
Now my question is will it impact the site in anyway? My angular lib value is as below
"lib": [
"es2018",
"dom",
"esnext.array"
]
Can somebody point me out the risk for adding esnext.array into the tsconfig.json file if any?