Cramping on and off

36 weeks today and for the past week I’ve been having slight cramps on and off. I’ve heard of people having this for weeks before they go into labor. Did this happen to you & how long did you have them before you gave birth?