Repository navigation
[labs/react] Fix style attribute conflicts with the type definition of DOM and ReactModule - #3048
indigostar-kr wants to merge 2 commits into
Conversation
…nition of dom and React Fixed lit#3021
🦋 Changeset detectedLatest commit: e20b798 The changes in this PR will be included in the next version bump. Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
justinfagnani
left a comment
There was a problem hiding this comment.
Thanks @indigostar-kr !
We'll need some tests here that show we get a build error without the fix. Can you make a test that contains JSX with a style binding? We have one in the tests already with a cast to any, so hopefully that can be removed.
| type UserProps = React.PropsWithChildren< | ||
| React.PropsWithRef< | ||
| Partial<Omit<I, 'children'>> & | ||
| Partial<Omit<I, 'children' | 'style' | 'ref' | 'key'>> & |
There was a problem hiding this comment.
Do we need to add className here too?
There was a problem hiding this comment.
It seems that both class and className should be included.
I'll check the test code and see if I can write it. |
…ties when react properties
|
This PR might be resolved with #3072 :) curious if that can be confirmed |
|
resolved with #3072 |
|
oops thought this was an issue my bad, reopened |
Style that conflicts with children, ref, and key, which are reserved words in React, is omitted from the properties of the web component.
Fixes [labs/react] createComponent React component style property typescript problem #3021
Added a default value for the type because if no Events were dispatched I got the following error: