Are there Save States? Or some version of this?

I love using cursor. The only issue is I’m frequently breaking my app, breaking key features or styling. I would love a way to save the state of my project that I can revert to after I make a world ending error. If there’s a way to do that, let me know. Or if you have suggestions on how to back up my files. Right now I just make copies of my src folder periodically. (I’m coding using react.)

Thank you!