Whisk egg yolks with sugar and vanilla extract using an electric whisk for a few minutes until pale then add the corn starch and whisk for another minute.
Slowly pour the hot milk into the egg mixture while whisking continuously.
Pour it all back into the sauce pan and cook over medium low heat until it thickens for about 5-6 minutes, never stop stirring.
Remove from heat, add the chocolate and butter, whisk until smooth and completely blended.
Cover with cling film to prevent it from a skin forming, the plastic needs to be in contact with the cream.
When it comes to room temp, refrigerate.
Notes
It can be kept in the fridge for up to three days.
Whisk with an electric mixer for 15-20 seconds before using to have a smooth and spreadable texture.
Recipe by HatiBon English at https://www.hatibon.com/blog/2016/07/chocolate-pastry-cream-creme-patissiere/