refactor(router): compile router cleanly with TypeScript 2.4 (#18465)
This commit is contained in:

committed by
Victor Berchet

parent
71de92a189
commit
4176832266
@ -45,7 +45,7 @@ describe('config', () => {
|
||||
expect(() => {
|
||||
validateConfig([
|
||||
{path: 'a', component: ComponentA},
|
||||
[{path: 'b', component: ComponentB}, {path: 'c', component: ComponentC}]
|
||||
[{path: 'b', component: ComponentB}, {path: 'c', component: ComponentC}] as any
|
||||
]);
|
||||
}).toThrowError(`Invalid configuration of route '': Array cannot be specified`);
|
||||
});
|
||||
|
@ -1820,7 +1820,7 @@ describe('Integration', () => {
|
||||
|
||||
function delayPromise(delay: number): Promise<boolean> {
|
||||
let resolve: (val: boolean) => void;
|
||||
const promise = new Promise(res => resolve = res);
|
||||
const promise = new Promise<boolean>(res => resolve = res);
|
||||
setTimeout(() => resolve(true), delay);
|
||||
return promise;
|
||||
}
|
||||
|
Reference in New Issue
Block a user