Slightly beat the two egg yolks and set them aside in a separate mixing bowl.
Mix sugar, cornstarch, and salt in a 2 qt saucepan.
Slowly stir in the milk.
Cook over medium heat, stirring constantly until the mixture thickens and boils.
Once the mixture is boiling, remove it from the heat and slowly pour half of the mixture into the egg yolks while rapidly whisking.
Once it's thoroughly mixed, add the egg mixture back into the saucepan with the hot mixture.
Boil and stir for another minute or so until it is a nice thick consistency.
Remove from heat and stir in the vanilla and butter.
Let cool before filling the cream into your puffs.