I have been trying to figure this out for over a week now. I can't seem to be able to clear my filters without breaking them. I need a button that clears all the filters on my screen so the user does not have to do them one by one.
Here is my stackblitz link for the sample code. Does anyone know how to make this work? I am starting to think there is a bug in the new PrimeNG Table filter process.
https://stackblitz.com/edit/clear-filters?file=src/app/app.component.ts
Pass your
p-tablereference variable#mydtto your clear function like followingapp.component.htmland use
table.clear()methodapp.component.tsI have updated your
stackblitz:https://stackblitz.com/edit/clear-filters-6jxnp3?file=src/app/app.component.ts