Skip to content

feat: LSP hover with resolved CFN properties and template locations#1669

Open
megha-narayanan wants to merge 5 commits into
aws:feat/cdk-lspfrom
megha-narayanan:feat/explorer-lsp-hover
Open

feat: LSP hover with resolved CFN properties and template locations#1669
megha-narayanan wants to merge 5 commits into
aws:feat/cdk-lspfrom
megha-narayanan:feat/explorer-lsp-hover

Conversation

@megha-narayanan

@megha-narayanan megha-narayanan commented Jun 24, 2026

Copy link
Copy Markdown
  • Adds LSP hover on construct creation lines showing the resolved CloudFormation logical ID, resource type, construct path, and top-level CFN properties with values
  • Each property value links to its exact line in the synthesized template; the logical ID header links to the resource block
  • Multi-resource constructs show auxiliaries inline (≤5 listed individually, >5 collapsed to a type histogram like "6× Subnet, 3× RouteTable")
  • Extends template-ranges.ts with resolveResourceRanges / indexTemplateRanges to resolve per-property character ranges in a single parse
  • Exports cfnProperties from the construct tree builder so the hover has access to resolved property values

example hover:
Screenshot 2026-06-24 at 12 12 52 PM

Screenshot 2026-06-24 at 12 13 44 PM

Fixes #

Checklist

  • This change contains a major version upgrade for a dependency and I confirm all breaking changes are addressed
    • Release notes for the new version:

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache-2.0 license

…te links

Hovering a construct's creation line surfaces its synthesized CloudFormation property values, with each value linking to its location in the template. Adds the cfnProperties attribute to the construct tree, resolveResourceRanges for per-property template ranges, a pure hover content builder, and the onHover server wiring.
Signed-off-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
@megha-narayanan megha-narayanan changed the title feat: LSP hover with resolved CFN properties and template locs feat: LSP hover with resolved CFN properties and template locations Jun 24, 2026
@megha-narayanan megha-narayanan marked this pull request as ready for review June 24, 2026 16:15
Signed-off-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
First-letter-upper only capitalized the first character, so properties whose CloudFormation name has an uppercase acronym run (SSESpecification, EnableECSManagedTags, TemplateURL) did not link and rendered as plain text. The L1 camelCase name and the template PascalCase name differ only in letter case, so key both sides lower-cased. Removes pascalCase.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants