Here's the rule of thumb: your actions will reinforce or deter the behaviour which has happened in the last 3 seconds.
It sounds simple enough, until you start to think about it. It means that every reward or punishment must happen immediately or else a parent can end up reinforcing the wrong type of behaviour.
Here's a common example: the child has been asked to do something in exchange for a reward. The child completes the task and then asks for the reward. The parent gives the reward.
The behaviour that has been reinforced is asking for the reward. In order to reinforce completing the task, the reward needed to be given promptly at the end of the task.
On the flip side, the child has been asked to do something in exchange for a reward. The child begins to protest. The parent offers an alternative "more fun" way to do the task. The child completes the task, the parent gives the reward.
The parent has reinforced protesting and completing the task.
This is one reason why it is critical to have rewards and deterrents planned out in advance. Not only is it necessary for consistency, but there simply isn't the time to decide things in the moment.
This kind of thinking isn't intuitive and while it can help in neurotypical parenting, it isn't always as necessary once the child reaches an age where they can be reasoned with and things can be explained. There is a certain social understanding in neurotypical families, that the parent is giving some indulgence now but expects the child to toe the line later. In autism, the child can't understand that kind of social exchange. That's why it all has to be kept consistent.