-
Notifications
You must be signed in to change notification settings - Fork 41
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
Another no-incompatible-type-binding issue, can't assign string[] to Iterable<string> #381
Comments
Well I've been down quite the rabbit hole today. 🙂 Seeing that |
Sigh and now -- as soon as I post the above -- my isolated experiment is correctly disallowing assigning |
I've been further into this, and even though |
Thanks for lit-analyzer/lit-plugin!
I'm getting the
no-incompatible-type-binding
error with a simple case of assigning astring[]
to a property of typeIterable<string> | undefined
. Component:This usage fails:
Error:
Clearly,
string[]
is assignable toIterable<string> | undefined
. (I try never to use an array type for properties/parameters/etc. where anIterable
will do.)Changing the type on
items
tostring[]
(or its other name,Array<string>
) makes the error go away, but unnecessarily limits the property.Some related issues, there seems to be a fundamental issue with the type checking:
#149, #154, #163, #356
TIA!
The text was updated successfully, but these errors were encountered: