There’s strong consensus in the therapist community that beating your kids is extremely bad for them, and for the relationship of trust between you.
It also teaches children that it’s appropriate to use violence to solve situations, especially situations involving getting your way. Kids that are spanked are much more likely to themselves be aggressive and hit other kids.