I think the problem is not that yorkies don't get along with young children, it's that young children can be a danger to yorkies, especially smaller yorkies.
I would advise you to think the decision over very carefully though. I've seen it happen
numerous times - a couple gets a yorkie (having a desire for a little one to care for) a year or so later has a baby. And, the yorkie often is then, maybe not neglected but doesn't get enough attention. I see yorkies and other small dogs rehomed on Craigslist quite often, for this very reason, and I always just hate to see it.