Skip to content

[lit-html] styleMap does not work with camel cased custom properties. #3738

@sorvell

Description

@sorvell

Which package(s) are affected?

Lit Core (lit / lit-html / lit-element / reactive-element)

Description

Given a custom property like --fooBar, on first render only styleMap will render this as --foo-bar and therefore not apply as expected.

Reproduction

https://lit.dev/playground/#gist=a6e74cd1d09dbae7ebcc3bb9ce0abaac

Workaround

Avoid using custom properties with upper case characters.

Is this a regression?

Yes. This used to work, but now it doesn't.

Affected versions

all

Browser/OS/Node environment

All

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

Status

✅ Done

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions