How to detect row visibility?

How to detect if row hidden or not?

If we are talking about a row hidden by filtering api, you can use

grid.getRowIndex(id)

it will return -1 for hidden rows.