Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Conversation

@justinfagnani
Copy link
Collaborator

Starting to work on go to definition for templates. I'm sure there are a bunch more cases we need to consider.

This only works for same package definitions, since we're not analyzing node_modules.

I didn't test this in VS Code, only via the unit test.

I'm not sure when getDefinitionAndBoundSpan() is called either.

@justinfagnani justinfagnani requested a review from rictic August 20, 2025 04:17
@changeset-bot
Copy link

changeset-bot bot commented Aug 20, 2025

🦋 Changeset detected

Latest commit: b08ac79

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 1 package
Name Type
@lit-labs/tsserver-plugin Patch

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@github-actions
Copy link
Contributor

github-actions bot commented Aug 20, 2025

📊 Tachometer Benchmark Results

Summary

nop-update

  • this-change, tip-of-tree, previous-release: unsure 🔍 -5% - +9% (-0.63ms - +1.13ms)
    this-change vs tip-of-tree

render

  • this-change: 44.23ms - 54.84ms
  • this-change, tip-of-tree, previous-release: unsure 🔍 -1% - +9% (-0.10ms - +1.77ms)
    this-change vs tip-of-tree
  • this-change, tip-of-tree, previous-release: unsure 🔍 -1% - +4% (-0.35ms - +1.69ms)
    this-change vs tip-of-tree
  • this-change, tip-of-tree, previous-release: unsure 🔍 -29% - +22% (-15.30ms - +11.85ms)
    this-change vs tip-of-tree

update

  • this-change: 508.92ms - 514.10ms
  • this-change, tip-of-tree, previous-release: unsure 🔍 -5% - +6% (-2.16ms - +2.70ms)
    this-change vs tip-of-tree
  • this-change, tip-of-tree, previous-release: unsure 🔍 -2% - +2% (-1.91ms - +1.54ms)
    this-change vs tip-of-tree
  • this-change, tip-of-tree, previous-release: unsure 🔍 -0% - +2% (-2.57ms - +10.35ms)
    this-change vs tip-of-tree

update-reflect

  • this-change: 496.11ms - 499.86ms
  • this-change, tip-of-tree, previous-release: unsure 🔍 -1% - +1% (-3.27ms - +3.81ms)
    this-change vs tip-of-tree

Results

this-change

render

VersionAvg timevs
44.23ms - 54.84ms-

update

VersionAvg timevs
508.92ms - 514.10ms-

update-reflect

VersionAvg timevs
496.11ms - 499.86ms-
this-change, tip-of-tree, previous-release

render

VersionAvg timevs this-change
vs tip-of-tree
tip-of-tree
vs previous-release
previous-release
this-change
20.57ms - 21.90ms-unsure 🔍
-1% - +9%
-0.10ms - +1.77ms
unsure 🔍
-0% - +8%
-0.05ms - +1.67ms
tip-of-tree
tip-of-tree
19.75ms - 21.06msunsure 🔍
-8% - +0%
-1.77ms - +0.10ms
-unsure 🔍
-4% - +4%
-0.87ms - +0.82ms
previous-release
previous-release
19.89ms - 20.97msunsure 🔍
-8% - +0%
-1.67ms - +0.05ms
unsure 🔍
-4% - +4%
-0.82ms - +0.87ms
-

update

VersionAvg timevs this-change
vs tip-of-tree
tip-of-tree
vs previous-release
previous-release
this-change
42.87ms - 46.20ms-unsure 🔍
-5% - +6%
-2.16ms - +2.70ms
unsure 🔍
-4% - +6%
-1.53ms - +2.72ms
tip-of-tree
tip-of-tree
42.49ms - 46.03msunsure 🔍
-6% - +5%
-2.70ms - +2.16ms
-unsure 🔍
-4% - +6%
-1.88ms - +2.53ms
previous-release
previous-release
42.62ms - 45.26msunsure 🔍
-6% - +3%
-2.72ms - +1.53ms
unsure 🔍
-6% - +4%
-2.53ms - +1.88ms
-

nop-update

VersionAvg timevs this-change
vs tip-of-tree
tip-of-tree
vs previous-release
previous-release
this-change
12.24ms - 13.65ms-unsure 🔍
-5% - +9%
-0.63ms - +1.13ms
unsure 🔍
-5% - +10%
-0.66ms - +1.22ms
tip-of-tree
tip-of-tree
12.17ms - 13.22msunsure 🔍
-9% - +5%
-1.13ms - +0.63ms
-unsure 🔍
-6% - +7%
-0.78ms - +0.85ms
previous-release
previous-release
12.04ms - 13.28msunsure 🔍
-9% - +5%
-1.22ms - +0.66ms
unsure 🔍
-7% - +6%
-0.85ms - +0.78ms
-
this-change, tip-of-tree, previous-release

render

VersionAvg timevs this-change
vs tip-of-tree
tip-of-tree
vs previous-release
previous-release
this-change
38.29ms - 39.85ms-unsure 🔍
-1% - +4%
-0.35ms - +1.69ms
unsure 🔍
-3% - +3%
-1.09ms - +1.06ms
tip-of-tree
tip-of-tree
37.75ms - 39.05msunsure 🔍
-4% - +1%
-1.69ms - +0.35ms
-unsure 🔍
-4% - +1%
-1.67ms - +0.30ms
previous-release
previous-release
38.35ms - 39.82msunsure 🔍
-3% - +3%
-1.06ms - +1.09ms
unsure 🔍
-1% - +4%
-0.30ms - +1.67ms
-

update

VersionAvg timevs this-change
vs tip-of-tree
tip-of-tree
vs previous-release
previous-release
this-change
88.48ms - 91.20ms-unsure 🔍
-2% - +2%
-1.91ms - +1.54ms
unsure 🔍
-2% - +2%
-2.24ms - +1.42ms
tip-of-tree
tip-of-tree
88.96ms - 91.08msunsure 🔍
-2% - +2%
-1.54ms - +1.91ms
-unsure 🔍
-2% - +2%
-1.85ms - +1.39ms
previous-release
previous-release
89.02ms - 91.47msunsure 🔍
-2% - +3%
-1.42ms - +2.24ms
unsure 🔍
-2% - +2%
-1.39ms - +1.85ms
-
this-change, tip-of-tree, previous-release

render

VersionAvg timevs this-change
vs tip-of-tree
tip-of-tree
vs previous-release
previous-release
this-change
41.09ms - 60.10ms-unsure 🔍
-29% - +22%
-15.30ms - +11.85ms
unsure 🔍
-39% - +3%
-25.27ms - +3.30ms
tip-of-tree
tip-of-tree
42.62ms - 62.02msunsure 🔍
-24% - +31%
-11.85ms - +15.30ms
-unsure 🔍
-37% - +7%
-23.67ms - +5.15ms
previous-release
previous-release
50.91ms - 72.25msunsure 🔍
-9% - +53%
-3.30ms - +25.27ms
unsure 🔍
-12% - +48%
-5.15ms - +23.67ms
-

update

VersionAvg timevs this-change
vs tip-of-tree
tip-of-tree
vs previous-release
previous-release
this-change
518.72ms - 530.35ms-unsure 🔍
-0% - +2%
-2.57ms - +10.35ms
unsure 🔍
-0% - +2%
-0.40ms - +12.93ms
tip-of-tree
tip-of-tree
517.83ms - 523.47msunsure 🔍
-2% - +0%
-10.35ms - +2.57ms
-unsure 🔍
-0% - +1%
-1.94ms - +6.68ms
previous-release
previous-release
515.01ms - 521.54msunsure 🔍
-2% - +0%
-12.93ms - +0.40ms
unsure 🔍
-1% - +0%
-6.68ms - +1.94ms
-

update-reflect

VersionAvg timevs this-change
vs tip-of-tree
tip-of-tree
vs previous-release
previous-release
this-change
529.49ms - 534.25ms-unsure 🔍
-1% - +1%
-3.27ms - +3.81ms
unsure 🔍
-0% - +1%
-1.96ms - +6.75ms
tip-of-tree
tip-of-tree
528.97ms - 534.22msunsure 🔍
-1% - +1%
-3.81ms - +3.27ms
-unsure 🔍
-0% - +1%
-2.37ms - +6.62ms
previous-release
previous-release
525.83ms - 533.12msunsure 🔍
-1% - +0%
-6.75ms - +1.96ms
unsure 🔍
-1% - +0%
-6.62ms - +2.37ms
-

tachometer-reporter-action v2 for Benchmarks

@justinfagnani justinfagnani force-pushed the tsserver-go-to-definition branch from 86971be to 8519905 Compare August 21, 2025 03:55
@github-actions
Copy link
Contributor

The size of lit-html.js and lit-core.min.js are as expected.

Base automatically changed from tsserver-plugin-next to main August 22, 2025 17:48
@justinfagnani justinfagnani force-pushed the tsserver-go-to-definition branch from 8519905 to b08ac79 Compare August 22, 2025 18:34
@justinfagnani justinfagnani changed the title [labs/tsserver-plugin] WIP: Add getDefinitionAtPosition() [labs/tsserver-plugin] Add getDefinitionAtPosition() Aug 22, 2025
@justinfagnani justinfagnani marked this pull request as ready for review August 22, 2025 19:29
@justinfagnani justinfagnani merged commit 069bafe into main Aug 22, 2025
10 checks passed
@justinfagnani justinfagnani deleted the tsserver-go-to-definition branch August 22, 2025 19:29
@lit-robot lit-robot mentioned this pull request Dec 18, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants