converting grid to a react component