The floor was ripped out for everyone when I found out. We had what I thought and many others thought was a great marriage and family. We told my kids 10 and 6 at the time that mom had a boyfriend.
Alot of evidence says don't tell, but I've preached to my kids forever- don't lie, the truth is always the best route. I couldn't be complicit with half truthing them or lying to them. The evidence either way is shaky. Most says don't tell or do something age appropriate. Other evidence says in the end when the kids find out they will hold some resentment to both for not being honest. I don't agree with holding the reality from children, especially in the light of life changing circumstances. I also immediately told them that people make mistakes and that their mom is not a horrible person. That she loves them and this was not a reflection of her love for them. That they would need to forgive her.
A few months after that we went through a year of false reconciliation where she cheated the entire time and on the 2nd telling - we told them we couldn't make it work.
Personally I believe in being forthright with them. Why put them in limbo of trying to put all the broken puzzle pieces together. That's maddening and unfair.
I've really struggled over if it was the right decision or not. Each situation is unique and probably should handled that way.
Since then I've never bad mouthed their mother or disclosed any details. They got a big picture answer in the begging and I would probably do the same thing again.
It's a really tuff call and one of the more ugly things you have to face as a betrayed spouse. If you believe honesty is the best policy then it's hard to go against it.
There is no right way to destroy their safety of a 2 parent home. In the end how you support them after divorce matters so much more. My EX has done a good job in that respect and I have too.
I believe you have to follow your values and try to protect them from the ugliness of it all as best you can. I can say I didn't make that call out of anger. And believe me the shit that went down was as ugly as could be.
No one, even the best pyschiatrist in the world has a proven list of best practices for the most appropriate way to eat a shit sandwich you have no idea how to digest.
One day when they are much older they may ask me what really happened. I don't know how I'll handle all of that. You would hope that your cheater would take that burden on themselves, but I wouldn't count on it.
If they learn anything from this I hope that it is, honesty is the best route. Also that they don't ever have to stick around if someone is treating them in a toxic manner. You can always forgive but don't have to be a doormat.