Later in the book God blessed them again and restored their riches and children...but no one mentions she had to go through 10 more pregnancies and get 10 more children through their running around years to adulthood.
And when God was rebuking Job's friends for giving pat answers about how or why God does what He does, He didn't rebuke Job's wife.
Psalm 103: 13, 14 "Just as a father has compassion on his children, so the Lord has compassion on those who fear Him. For He Himself knows our frame, that we are but dust."
He can handle our frustrations and even anger, as long as we don't turn our back on Him, because He knows we are unaware of the ending of the story.
Job 23:10 "He knows the way that I take; when he has tested me, I will come forth as gold."