Skip to content

Regression with types after Attachments #15924

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
huntabyte opened this issue May 15, 2025 · 3 comments
Closed

Regression with types after Attachments #15924

huntabyte opened this issue May 15, 2025 · 3 comments

Comments

@huntabyte
Copy link
Member

huntabyte commented May 15, 2025

Describe the bug

When using HTMLAttributes<HTMLElement> as the props type for a component, where children is optional, if you don't provide children explicitly, by putting content within the components children or setting children={undefined} you get a type error.

Image

It seems to occur specifically when Partial<> is used.

Reproduction

https://github.com/huntabyte/attachments-type-issue

Go to lib/another.svelte to see the behavior.

Logs

System Info

System:
    OS: macOS 15.2
    CPU: (12) arm64 Apple M2 Max
    Memory: 143.69 MB / 32.00 GB
    Shell: 5.9 - /bin/zsh
  Binaries:
    Node: 20.18.0 - ~/.nvm/versions/node/v20.18.0/bin/node
    npm: 10.8.2 - ~/.nvm/versions/node/v20.18.0/bin/npm
    pnpm: 9.14.4 - ~/Library/pnpm/pnpm
    bun: 1.0.25 - ~/.bun/bin/bun
  Browsers:
    Edge: 136.0.3240.64
    Safari: 18.2
  npmPackages:
    svelte: ^5.0.0 => 5.30.1

Severity

blocking an upgrade

@paoloricciuti
Copy link
Member

Image

Mmm can't seem to reproduce

@huntabyte
Copy link
Member Author

It reveals itself with svelte-check really

@paoloricciuti
Copy link
Member

Uh i just needed to install lol...however this is fixed by #15939

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy