Skip to content

Commit

Permalink
fix: account for added code in the range of inlay hint (#2387)
Browse files Browse the repository at this point in the history
  • Loading branch information
jasonlyu123 authored Jun 3, 2024
1 parent 2478212 commit 89ee707
Showing 1 changed file with 3 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -18,12 +18,13 @@ export function decorateInlayHints(
}

const { languageService, toVirtualPos, toOriginalPos } = result;
const start = toVirtualPos(span.start);
return languageService
.provideInlayHints(
fileName,
{
start: toVirtualPos(span.start),
length: span.length
start,
length: toVirtualPos(span.start + span.length) - start
},
preferences
)
Expand Down

0 comments on commit 89ee707

Please sign in to comment.