Even if it is "just IBS" this can be debilitating. I have a lot of GI damage due to IBD but my inflammation markers are so low its crazy. They told me for 10+ years it was IBS, bc I have anxiety attacks. Now they are saying IBD.
Regardless of diagnosis, most important is diet. You may benefit from a food allergy test. Or if you have the discipline you can try an elimination diet. Or at the least keep a journal and include life stressors, mood and food. All of which is honestly kind of hard for me to keep track of but super beneficial. Also, B12 deficiency can cause all sorts of havoc on multiple systems. I am starting the Simple Carbohydrate Diet for my IBD. Drinking enough water is incredibly important as well. Just be vigilant and during flare ups adjust eating to foods known to heal you. Good luck :)