You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
After I upgrade from "typescript": "~3.5.3" to "typescript": "~3.8.2" I start to get
the following error:
src/schematics-utils/schematics.utils.ts:39:33 - error TS2345: Argument of type 'import("/../node_modules/typescript/lib/typescript").SourceFile' is not assignable to parameter of type 'import("/../node_modules/schematics-utilities/node_modules/@schematics/angular/third_party/github.com/Microsoft/TypeScript/lib/typescript").SourceFile'.
Types of property 'kind' are incompatible.
Type 'import("/../node_modules/typescript/lib/typescript").SyntaxKind.SourceFile' is not assignable to type 'import("/../node_modules/schematics-utilities/node_modules/@schematics/angular/third_party/github.com/Microsoft/TypeScript/lib/typescript").SyntaxKind.SourceFile'.
39 const change = insertImport(sourceFile, pathFileToEdit, importSymbolName, importPath, isDefault) as InsertChange;
~~~~~~~~~~
I have a utils imports in my code
import * as ts from 'typescript';
import { InsertChange, insertImport } from 'schematics-utilities';
}
in case I'm replace the type ts.SourceFile to any the build work but I want to keep the type
I think it happen since the
The text was updated successfully, but these errors were encountered:
With cast to any it will build but it doesn't work as excepted. Always added imports, also if there are already there (Seems like the SourceFile analysis isn't working correct).
For me, i just copied the relevant parts into my project - now everything is working.
After I upgrade from "typescript": "~3.5.3" to "typescript": "~3.8.2" I start to get
the following error:
I have a utils imports in my code
in case I'm replace the type ts.SourceFile to any the build work but I want to keep the type
I think it happen since the
The text was updated successfully, but these errors were encountered: