This is called spontaneous recovery. To help this method be even more powerful, always replace bad behaviors with good behaviors. If you plan to ignore your puppy for barking, you will be much more likely to succeed if you also teach him an acceptable way to gain your attention. Teach him that if he sits in front and watches you, you will pay attention to him. If he barks, you will stare at the ceiling for 30 seconds.
Puppies find time out punishing as well, especially if it means being separated from the family.
Suppose you give your puppy a tasty chew toy and he chooses to jump and grab at your clothes instead. Reprimand him verbally and direct him back to his toy. If he persists, calmly, without emotion, and with minimal interaction , either leave the room or remove the puppy to a time-out area. Time him out for no more than 30 seconds. Believe it or not, anything longer than 30 seconds is less effective.