Skip to content

svelte-check and LSP error on bind:clientWidth with transform syntax #15482

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
midzelis opened this issue Mar 10, 2025 · 1 comment
Closed

svelte-check and LSP error on bind:clientWidth with transform syntax #15482

midzelis opened this issue Mar 10, 2025 · 1 comment

Comments

@midzelis
Copy link
Contributor

Describe the bug

Using this syntax causes a syntax error in svelte-check and the LSP:

Object literal may only specify known properties, and '"bind:clientWidth"' does not exist in type 'HTMLProps<"section", HTMLAttributes<any>>'.ts(2353)

Reproduction

<div bind:clientWidth={null, (v) => ((myModel.viewportWidth = v), myFn())}

Logs

System Info

System:
    OS: Linux 6.8 Debian GNU/Linux 12 (bookworm) 12 (bookworm)
    CPU: (32) x64 AMD Ryzen 9 5950X 16-Core Processor
    Memory: 21.70 GB / 30.27 GB
    Container: Yes
    Shell: 5.2.15 - /bin/bash
  Binaries:
    Node: 22.14.0 - ~/.volta/tools/image/node/22.14.0/bin/node
    npm: 10.9.2 - ~/.volta/tools/image/node/22.14.0/bin/npm
  npmPackages:
    svelte: ^5.17.4 => 5.20.5

Severity

annoyance

@jasonlyu123
Copy link
Member

Closing in favour of sveltejs/language-tools#2741

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

No branches or pull requests

2 participants