Not working properly with react version 18
It creates duplicate row and columns both with react version 18

I have the same issue...
same ... it's not working with react v18
There is a fork of this repo published in issue #150
@gmanikamevd It would be nice to see a small reproduction of the issue.
But I assume that you have some setState in the parent component.
Also, I assume you are listening to onChange event on PivotTable, and change the state in onChange callback.
Also, I assume you pass that props to PivotTable as props.
If I describe the situation correctly then wrapping setState with flushSync will help