Nobody decides to be transgender, or chooses this life. It is difficult for everybody involved, but chiefly, it is difficult for the person that you have known as your husband. Most individuals who are transgender have known this from a young age, and without education to help them understand their impulses, live in painful denial. We do not choose to suffer, or to make others suffer. If a person is motivated to transition, they are doing so because they are in an extreme amount of pain otherwise, and there is no other choice. My heart breaks for you, that society has prevented your partner from transitioning earlier, and so you both face this challenge partway through your marriage. It is a devastating consequence of a deeply transphobic society, which did not allow your partner the knowledge which could have allowed "him" to transition to "her" earlier.
It's important to note that not all couples break up because one partner transitions. It depends greatly from circumstance to circumstance. Couples therapy and open communication is essential, if you are to get through this. Your mental health matters, and so does theirs. Your partner should be talking with you, and you should be working together to make a decision regarding your children's future.
Here are some resources/stories that might help you:
Here is an allies/family support network:
Here is a support network for families of transgender people:
Here is a Facebook page for partners of transgender people:
Here is the story of Janet Rice and Penny Whetton. They married before Penny transitioned to female, but stayed together. This was before marriage equality in Australia.
Here is a page about transgender people, with information to learn more.
I would also suggest watching the movie A Danish Girl, which is dramatised, but nonetheless you may relate to it.
You might stay with your partner, you might not. I wish I could give you a hug. This is a difficult time. I would seriously suggest attending therapy, both alone and with your partner. You fell in love with a man, so there is mourning which will occur. Your partner should be opening up to you. A marriage is a partnership.