Heat the milk until steaming. Whisk the yolks, sugar and cornstarch in a bowl, then slowly whisk in the hot milk.
Return to the pan and whisk over medium heat until it bubbles and thickens, about 2 minutes. Off the heat, whisk in the butter and vanilla. Press plastic wrap onto the surface and chill.
Heat the oven to 400°F (200°C) and line a baking sheet with parchment. Bring the milk, water, butter, sugar and salt to a boil.
Add the flour all at once and stir hard over low heat 1 to 2 minutes, until the dough comes away from the pan. Cool 5 minutes.
Beat in the eggs one by one until the dough is glossy and falls from the spoon in a thick ribbon (you may not need the last egg).
Pipe 3-inch strips 2 inches apart. Bake 20 minutes, then lower the heat to 325°F (160°C) and bake 15 to 20 minutes more, until crisp. Cool on a rack.
Poke a small hole in each end and pipe in the pastry cream.
Melt the chocolate with the butter, dip the tops of the éclairs and chill until set.