I have an HTML code which includes this...
My function in typescript is this...
It's giving me the following error.
Error: src/app/components/edit-delete-item/edit-delete-item.component.html:4:51 - error TS2345: Argument of type 'Event' is not assignable to parameter of type 'Sort'.
Type 'Event' is missing the following properties from type 'Sort': active, direction
4 <table matSort (matSortChange)= "sortData($event)">
It's the exact same code as I used in another program that worked just fine, and I don't get why it's not working. I have reviewed the code that is working, and made sure it matched this exactly other than the object names, and it's not working here.
Why am I getting this error?