refactor(core): remove deprecated OpaqueToken
(#18971)
BREAKING CHANGE: `OpaqueToken` has been removed as it was deprecated since v4. Use `InjectionToken` instead. PR Close #18971
This commit is contained in:

committed by
Miško Hevery

parent
36d37cc6ae
commit
3c4eef8a86
@ -734,10 +734,8 @@ describe('Collector', () => {
|
||||
it('should treat exported class expressions as a class', () => {
|
||||
const source = ts.createSourceFile(
|
||||
'', `
|
||||
export const InjectionToken: {new<T>(desc: string): InjectionToken<T>;} = class extends OpaqueToken {
|
||||
constructor(desc: string) {
|
||||
super(desc);
|
||||
}
|
||||
export const InjectionToken: {new<T>(desc: string): InjectionToken<T>;} = class {
|
||||
constructor(protected _desc: string) {}
|
||||
|
||||
toString(): string { return \`InjectionToken ${this._desc}\`; }
|
||||
} as any;`,
|
||||
|
Reference in New Issue
Block a user