This repository has been archived by the owner on Jul 30, 2018. It is now read-only.
WidgetMixin#properties
should not be a Partial
#199
Milestone
Bug
Since
WidgetProperties
uses an index signature, it does not play nicely withPartial
. As a result, dot notation cannot be used to access concreteWidget#properties
values defined in interfaces that extendWidgetProperties
. This can be resolved by changingproperties: Partial<P>
to justproperties: P
within theWidgetMixin
interface.Package Version: v2.0.0-alpha.17
Code
Expected behavior:
The TypeScript compiler should not throw any errors when setting
customProperty
via dot notation.Actual behavior:
The TypeScript compiler throws the error:
Property 'customProperty' does not exist on type 'Partial<CustomProperties>'
.The text was updated successfully, but these errors were encountered: