Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(language-service): fix go to definition for template variables an… #40491

Closed
wants to merge 1 commit into from

Conversation

atscott
Copy link
Contributor

@atscott atscott commented Jan 19, 2021

RC version of #40455

…d references (angular#40455)

The current "go to definition" is broken for template variables and
references when a template is overridden. This is because we get the
file url from the source span, which uses the overridden name
'override.html'. Instead, we can retrieve the template file from the
compiler in the same manner that is done for references.

Another way to fix this would have been to use the real template file path when
overriding a template, but this was the more straightforward fix since
the strategy was already used in find references and rename locations.

fixes angular/vscode-ng-language-service#1054

PR Close angular#40455
@atscott atscott added area: language-service Issues related to Angular's VS Code language service target: rc This PR is targeted for the next release-candidate labels Jan 19, 2021
@ngbot ngbot bot added this to the Backlog milestone Jan 19, 2021
@google-cla google-cla bot added the cla: yes label Jan 19, 2021
@AndrewKushnir AndrewKushnir added PullApprove: disable action: merge The PR is ready for merge by the caretaker labels Jan 19, 2021
@AndrewKushnir
Copy link
Contributor

Closed by commit 3e134e4

AndrewKushnir pushed a commit that referenced this pull request Jan 19, 2021
…d references (#40455) (#40491)

The current "go to definition" is broken for template variables and
references when a template is overridden. This is because we get the
file url from the source span, which uses the overridden name
'override.html'. Instead, we can retrieve the template file from the
compiler in the same manner that is done for references.

Another way to fix this would have been to use the real template file path when
overriding a template, but this was the more straightforward fix since
the strategy was already used in find references and rename locations.

fixes angular/vscode-ng-language-service#1054

PR Close #40455

PR Close #40491
@angular-automatic-lock-bot
Copy link

This issue has been automatically locked due to inactivity.
Please file a new issue if you are encountering a similar or related problem.

Read more about our automatic conversation locking policy.

This action has been performed automatically by a bot.

@angular-automatic-lock-bot angular-automatic-lock-bot bot locked and limited conversation to collaborators Feb 19, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
action: merge The PR is ready for merge by the caretaker area: language-service Issues related to Angular's VS Code language service cla: yes PullApprove: disable target: rc This PR is targeted for the next release-candidate
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants