It's really important to take a step back before reacting to our child's behaviour and think about what it means to us. If we see the behaviour as a cry for help, we are going to respond much differently than if we see it as a need for discipline. We might not always be correct when we assess why a child is misbehaving, but taking the time to consider it will help us avoid automatic reactions. Then we can ask ourselves about the evidence for our assessment. Is it true? How do you know it's true?
I can't tell you the "correct" way of seeing your child's behaviour; it's possible that your child really is doing what they're doing to make you mad. However, it is important to consider where your attitude may land you. If you see your child's behaviour as something that needs to be punished, as them versus you, you will almost certainly get caught in a power struggle and a cycle of punishment and misbehaviour. If you see your child's behaviour as communication, it will be much easier to problem solve with your child to figure out what the difficulty is and how it can be fixed.
If you are interested in trying to see your child and their behaviour in a different way, the first thing to consider is that it's not about you. Everyone on the planet has one goal: to get their needs met. The most basic of those needs are hunger and sleep, but humans also have the need for empathy, belonging, autonomy and connection. We all struggle to find the best way to communicate our needs, but our children do most of all, especially when they are unable to verbalize them. As Thomas Gordon says, "The "badness'' of the behavior actually resides in the adult's mind, not the child's; the child in fact is doing what he or she chooses or needs to do to satisfy some need." This is not to say that you shouldn't teach your child a better way to meet their needs, but that instead of trying to "teach them a lesson" you will be trying to teach them a lesson.
For Further Thought:
1) Do you believe that your child's behaviour is communication? What do you believe it is trying communicate?
2) Have you considered the long term outcomes of your attitude towards behaviour? Where do you want to end up, and where do you think you'll end up as a result?
3) Are you able to step back from the behaviour and try to see the need behind it? How can you make this easier for yourself?
For Further Reading:
Abundant Life Children: Through Their Eyes: Keeping Our Expectations Developmentally Appropriate
Dan Gartrell: Guidance Matters