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

Use local ref. targets for count.index #160

Merged
merged 2 commits into from
Nov 22, 2022
Merged

Use local ref. targets for count.index #160

merged 2 commits into from
Nov 22, 2022

Conversation

radeksimko
Copy link
Member

@radeksimko radeksimko commented Nov 21, 2022

Depends on #159


This PR changes collection of reference targets, such that we now collect count.index as a target to the count attribute. This in turn enables go-to-definition and go-to-references between count and count.index.

Additionally, it updates completion, hover and semantic tokens, to make use of this reference target and just treat it like any other valid reference.

Lastly I updated the description of the count attribute to reflect what it does and also add the note about conflict we already have in the for_each description.


UX in Terraform

Completion (w/ updated description)

Screenshot 2022-11-21 at 17 52 19
Screenshot 2022-11-21 at 18 00 21

Hover (w/ updated description)

Screenshot 2022-11-21 at 17 52 45
Screenshot 2022-11-21 at 17 57 21

Go-to-* (new)

2022-11-21 17 57 49

@radeksimko radeksimko added the enhancement New feature or request label Nov 21, 2022
@radeksimko radeksimko requested a review from a team November 21, 2022 17:39
Copy link
Member

@dbanck dbanck left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM! Great job on outlining the UX impact

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants