In a bowl, whisk together the egg yolks, sugar (if using), and cornstarch until smooth and creamy.
Heat the milk in a saucepan over medium heat until it begins to steam, but not boil.
Slowly pour a small amount of the hot milk into the egg mixture, whisking constantly to temper the eggs.
Gradually add the rest of the milk, continuing to whisk.
Return the mixture to the saucepan and cook over medium heat, stirring constantly, until it thickens and coats the back of a spoon.
Remove from heat and stir in vanilla extract if desired.
Pour into a bowl, cover with plastic wrap directly on the surface to prevent a skin from forming, and let cool completely before using.
Serving and Storage Tips:
