feat(language-service): Add getTypeDefinitionAtPosition (go to type definition) (#39145)

This commit adds the implementation for providing "go to type definition"
functionality in the Ivy Language Service.

PR Close #39145
This commit is contained in:
Andrew Scott
2020-10-02 13:54:18 -07:00
committed by atscott
parent bf717b1a31
commit a84976fdfc
13 changed files with 579 additions and 102 deletions

View File

@ -8,10 +8,15 @@
import {Component} from '@angular/core';
export interface Address {
streetName: string;
}
/** The most heroic being. */
export interface Hero {
id: number;
name: string;
address?: Address;
}
@Component({

View File

@ -24,6 +24,7 @@ import * as ParsingCases from './parsing-cases';
ParsingCases.TestComponent,
ParsingCases.TestPipe,
ParsingCases.WithContextDirective,
ParsingCases.CompoundCustomButtonDirective,
]
})
export class AppModule {

View File

@ -12,6 +12,7 @@ import {Hero} from './app.component';
@Directive({
selector: '[string-model]',
exportAs: 'stringModel',
})
export class StringModel {
@Input() model: string = 'model';
@ -69,6 +70,11 @@ export class WithContextDirective {
}
}
@Directive({selector: 'button[custom-button][compound]'})
export class CompoundCustomButtonDirective {
@Input() config?: {color?: string};
}
@Pipe({
name: 'prefixPipe',
})