Property … does not exist on type ‘IntrinsicAttributes & …’

Components have only one parameter which is the props object, therefore your function should look something like this:

function MyCard(props: { param1: ObjectDto, toggleFunction: any }) {}

The type system is trying to match the properties with the first parameter of your function, which is of type ObjectDto. That’s why you get error

is not assignable to type ‘IntrinsicAttributes & ObjectDto’

Leave a Comment

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)