Skip to content

v-once inside v-for breaks intellisense #4827

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

Closed
dsvgl opened this issue Sep 8, 2024 · 0 comments · Fixed by #4830
Closed

v-once inside v-for breaks intellisense #4827

dsvgl opened this issue Sep 8, 2024 · 0 comments · Fixed by #4830
Labels
bug Something isn't working

Comments

@dsvgl
Copy link

dsvgl commented Sep 8, 2024

Vue - Official extension or vue-tsc version

2.1.6

VSCode version

1.93.0

Vue version

3.4.27

TypeScript version

5.4.5

System Info

System:
    OS: macOS 14.4
    CPU: (8) arm64 Apple M1 Pro
    Memory: 96.92 MB / 16.00 GB
    Shell: 5.9 - /bin/zsh
  Binaries:
    Node: 20.11.1 - ~/.volta/tools/image/node/20.11.1/bin/node
    Yarn: 1.22.18 - ~/.volta/tools/image/yarn/1.22.18/bin/yarn
    npm: 10.2.4 - ~/.volta/tools/image/node/20.11.1/bin/npm
    pnpm: 8.15.6 - ~/.volta/bin/pnpm
  Browsers:
    Chrome: 128.0.6613.120
    Edge: 128.0.2739.67
    Safari: 17.4
    Safari Technology Preview: 18.0

package.json dependencies

No response

Steps to reproduce

Check playground reproduction and hover over a variable (eg. page). See that nothing is happening. No Tooltip with type info and no intellisense for the whole component. Also, syntax highlighting is not working correctly either.

https://play.vuejs.org/#eNp9Ub1OwzAQfhXrlixtOsAU0kqAOsAACNgwQ0gvwW1iW7YTgqK8O2eb/gxVt9z3d9/FI9xqnfYdQga5w1Y3hcMVl4zl2uBqHJkuamTTlC/8vCdYP6+UWXIQ5GFCBlXqB8uBZTv8/edo6udKliEqiI9R+eJkIY22NEI7ZtF1mpBSSevi+iUb/eaQn7GPpFIqmbHkqzDJ54zL6caHRTsZYQbOkrsSdbq1StJpwc6hVK0WDZpn7QSlc8hisOeKplE/jwFzpkOKjXj5jeXuDL61g8c4vBi0aHrkcOBcYWp0kV6/PeFA3weyVZuuIfUF8hWtajrfMcruOrmh2ie60Pah1co4Iet3ux4cSrs/yhf1yinoOdD73l84/Vj3Kr0OPvqnMP0BVDqywg==

Remove the v-once inside the v-for loop and notice that now all mentioned problems are gone.

Placing a v-once on a single element (no v-for) works as expected.
So, it is only a problem when inside a v-for loop.

What is expected?

see text above

What is actually happening?

see text above

Link to minimal reproduction

https://play.vuejs.org/#eNp9Ub1OwzAQfhXrlixtOsAU0kqAOsAACNgwQ0gvwW1iW7YTgqK8O2eb/gxVt9z3d9/FI9xqnfYdQga5w1Y3hcMVl4zl2uBqHJkuamTTlC/8vCdYP6+UWXIQ5GFCBlXqB8uBZTv8/edo6udKliEqiI9R+eJkIY22NEI7ZtF1mpBSSevi+iUb/eaQn7GPpFIqmbHkqzDJ54zL6caHRTsZYQbOkrsSdbq1StJpwc6hVK0WDZpn7QSlc8hisOeKplE/jwFzpkOKjXj5jeXuDL61g8c4vBi0aHrkcOBcYWp0kV6/PeFA3weyVZuuIfUF8hWtajrfMcruOrmh2ie60Pah1co4Iet3ux4cSrs/yhf1yinoOdD73l84/Vj3Kr0OPvqnMP0BVDqywg==

Any additional comments?

No response

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants