Skip to content

Cannot use camel case properties with builtin custom elements (is attribute) #2823

@edoardocavazza

Description

@edoardocavazza

Describe the bug

The check for custom element node is incomplete here. It only checks for - in the tag name, but should also check for is attribute.

Reproduction

Consider the following snippet:

<div is="builtin-test" camelCase={true}></div>

when hovering the camelCase attribute you will see that it has been lowerized to camelcase. If someone defines the camelCase property, it won't work because typescript checks for the lower version camelcase.

Expected behaviour

Builtin custom elements should be treat as autonomous custom elements.

System Info

  • OS: [e.g. Windows]
  • IDE: [e.g. VSCode, Atom]

Which package is the issue about?

svelte2tsx

Additional Information, eg. Screenshots

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions