Skip to content
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

customElement option throws an error #189

Closed
Jeggle-s opened this issue Jun 28, 2023 · 2 comments
Closed

customElement option throws an error #189

Jeggle-s opened this issue Jun 28, 2023 · 2 comments
Labels
bug Something isn't working question Further information is requested

Comments

@Jeggle-s
Copy link

Jeggle-s commented Jun 28, 2023

Describe the bug
Today I upgraded esbuild-svelte to version 0.74 with Svelte 4 as dependency. In the migration guide it states, that the Tag-Option for custom components is deprecated with Svelte 4 and was replaced with the customElement option (see https://svelte.dev/docs/v4-migration-guide#custom-elements-with-svelte). Using this new option, the esbuild-svelte plugin throws following error:

<svelte:options> unknown attribute

To Reproduce
Steps to reproduce the behavior:

  1. Define a custom component tag with <svelte:options customElement="my-component">
  2. Include this component in an HTML file
  3. See error

Expected behavior
No error should be thrown. The error should only occur if the old option (tag) was used.

Environment:

  • esbuild-svelte version: 0.7.4
  • esbuild version: 0.17.5
  • Svelte preprocessors used (if any): svelte-preprocess - 5.0.3
@Jeggle-s Jeggle-s added the bug Something isn't working label Jun 28, 2023
@EMH333
Copy link
Owner

EMH333 commented Jun 28, 2023

I am unable to reproduce this issue when using Svelte 4. Are you sure you have upgraded to Svelte 4 (npm install svelte@4)?

@EMH333 EMH333 added the question Further information is requested label Jun 28, 2023
@Jeggle-s
Copy link
Author

Ah damn it. I did not update all my dependencies. Error was in front of the monitor. I'm closing this issue.

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

No branches or pull requests

2 participants