Recently, I delved into exploring the Ahead-of-time compilation cookbook for Angular and found it quite intriguing. However, it seems like the errors I am encountering are not directly related to my new venture. You can check out the cookbook here: https://angular.io/guide/aot-compiler
Using Visual Studio 2015, I upgraded my Angular 2 project to version 2.4 without any issues during the build process. Subsequently, I made a modification to my tsconfig.json file by adding
"lib": [ "es2015", "dom" ]
under compilerOptions. The updated file now appears as follows:
{
"compilerOptions": {
"target": "es5",
"module": "commonjs",
"moduleResolution": "node",
"sourceMap": true,
"emitDecoratorMetadata": true,
"experimentalDecorators": true,
"lib": [ "es2015", "dom" ],
"removeComments": false,
"noImplicitAny": true,
"outDir": "dist",
"suppressImplicitAnyIndexErrors": true
},
"compileOnSave": true
}
Upon rebuilding post this alteration, I encountered a new build error:
Build: duplicate identifier 'PropertyKey'.
Ongoing research led me to remove
"@types/core-js": "^0.9.34"
from my package.json file, which eliminated the prior error. However, new errors surfaced in multiple instances, including:
Build: Cannot find name 'Set'
Build: Cannot find name 'Promise'
Build: Cannot find name 'Map'
The entirety of my package.json file looks like this:
{
"name": "angular2-quickstart",
"version": "1.0.0",
// Remaining content goes here...
}
In order to stay informed about updates, I have been regularly referring to the dependencies section in the sample package.json file provided at: https://angular.io/guide/quickstart
Please note that while the referenced link is for the JavaScript version, I am actively using TypeScript 2.1.4. This may potentially lead to discrepancies within my file, but I'm unsure how to pinpoint these outdated sections specifically.