I am encountering around 7 errors with my TS compiler related to the transfer_state.d.ts file located in node_modules\@angular\platform-browser\src\browser\ directory
The line causing the issue is:
export declare function makeStateKey<T = void>(key: string): StateKey<T>;
The content of the entire file is as follows:
...
I have experimented with different TS compilers and made changes to the tsconfig.json file extensively. I even reinstalled Node to ensure that the file is not corrupted.
This error only occurs during compilation in Visual Studio 2015, but works fine when using ng server.
I require this to function properly in VS2015 but I am puzzled by what could be causing the issue.
My current versions are:
TypeScript 2.3.4 (tried others like 2.7.2 and 2.6.2) NPM version 5.6.0 Angular version 5.2.5 Angular CLI 1.7.1 Node 6.10.2 Webpack 3.11.0