Skip to content

Commit 38f7a34

Browse files
committed
refactor(cdk/portal): Deprecate ComponentType
Recommendation is to use `Type<T>` from `@angular/core` which has the exact same interface definition
1 parent 37513f5 commit 38f7a34

File tree

1 file changed

+11
-7
lines changed

1 file changed

+11
-7
lines changed

src/cdk/portal/portal.ts

Lines changed: 11 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -7,24 +7,28 @@
77
*/
88

99
import {
10-
TemplateRef,
11-
ViewContainerRef,
12-
ElementRef,
10+
Binding,
1311
ComponentRef,
12+
ElementRef,
1413
EmbeddedViewRef,
1514
Injector,
16-
Binding,
15+
TemplateRef,
16+
ViewContainerRef,
1717
} from '@angular/core';
1818
import {
19-
throwNullPortalOutletError,
20-
throwPortalAlreadyAttachedError,
2119
throwNoPortalAttachedError,
2220
throwNullPortalError,
21+
throwNullPortalOutletError,
22+
throwPortalAlreadyAttachedError,
2323
throwPortalOutletAlreadyDisposedError,
2424
throwUnknownPortalTypeError,
2525
} from './portal-errors';
2626

27-
/** Interface that can be used to generically type a class. */
27+
/**
28+
* Interface that can be used to generically type a class.
29+
*
30+
* @deprecated Use Type<T> from @angular/core instead.
31+
*/
2832
export interface ComponentType<T> {
2933
new (...args: any[]): T;
3034
}

0 commit comments

Comments
 (0)