feat(compiler-cli): add support for TypeScript 4.0 (#38076)

With this change we add support for TypeScript 4.0

PR Close #38076
This commit is contained in:
Alan Agius
2020-07-15 12:21:04 +02:00
committed by Misko Hevery
parent 201a546af8
commit 0fc44e0436
37 changed files with 315 additions and 141 deletions

View File

@ -33,7 +33,6 @@ import {Checks, getAllRouteGuards} from './utils/preactivation';
import {isUrlTree} from './utils/type_guards';
/**
* @description
*
@ -922,7 +921,7 @@ export class Router {
const {source, state, urlTree} = currentChange;
const extras: NavigationExtras = {replaceUrl: true};
if (state) {
const stateCopy = {...state};
const stateCopy = {...state} as Partial<RestoredState>;
delete stateCopy.navigationId;
if (Object.keys(stateCopy).length !== 0) {
extras.state = stateCopy;