vasturiano / kapsule

Kapsule - A closure based Web Component library
MIT License
58 stars 13 forks source link

Production build error #5

Closed BartosStore closed 2 years ago

BartosStore commented 2 years ago

Hi,

thanks for kapsule! I use kapsule/react-kapsule to integrate timeline-chart into react application.

I am happy with this combination but when I need to publish my project this error occurs:

TypeScript error in C:/dev/cs/condition_monitoring/condition_monitoring/Frontend/node_modules/kapsule/dist/kapsule.d.ts(39,3):
Property 'resetProps' of type '(() => KapsuleInstance) | undefined' is not assignable to string index type 'PropGetter | PropSetter | KapsuleMethod'.  TS2411
    37 | interface KapsuleInstance {
    38 |   (constructorItem: any): KapsuleInstance;
  > 39 |   resetProps?(): KapsuleInstance;
       |   ^
    40 |   [propOrMethod: string]: PropGetter | PropSetter | KapsuleMethod;
    41 | }
    42 |

Could you help me? Do you know where can be problem?

vasturiano commented 2 years ago

Thanks for the report @BartosStore.

I've updated the type definitions in this module which should solve your TS issue if you upgrade your dependency tree to the latest version of kapsule.