These really stupid activists and the legislators they influence have taken the control of obsessively defiant children away from the parent by threatening to jail them if they use physical means or verbal "abuse" to cause defiance to cease.
The time for corporal discipline is when children are quite young. A single spanking establishes that there are consequences for disobedience. That is enough for many kids. They have to know that you mean what you say and that you are in charge. That allows you to keep them safe.
If you make the point when they are 3 or 4 you can be really minimal, one swat. Depends on the kid but if you leave it too long to set the ground rules it is much more difficult and it’s no favor to the kid. They need to understand your expectations. The better your discipline the more freedom you can allow them because they will moderate their behavior right away when spoken to.