Should I breastfeed if I have ibs?

No. You will need to check with your OB and GI docs to clear your medications. Some of the meds used to treat IBS can be a risk for nursing infant. Note that many people with "ibs/ibd" actually have celiac disease. If you have not been tested for celiac, please ask your doc.
Yes. There are very few true contraindications to breastfeeding. According to the aap, IBS is not a reason to not breastfeed. If you have concerns about the medications that you might need to take, you can find information on lactmed, a free resource on medications and breastfeeding from the national library of medicine.