1) Combine the cornstarch, sugar and salt in a medium saucepan.
2) Slowly whisk in the coconut milk, in a thin steam at first so that lumps don’t form, then more quickly once the cornstarch mixture is smoothly incorporated.
3) Place over medium-low heat and stir occasionally, scraping the bottom and sides. Use a whisk as necessary should lumps begin to form. After 10 minutes or so (slower over lower heat is better, to give the cornstarch time to cook), before it starts to simmer, the mixture should begin to thicken, enough that it will coat the back of a spoon.
4) Add the chocolate, and continue stirring for another 2 to 4 minutes, until chocolate is fully incorporated and mixture is quite thick. Remove from heat and stir in the vanilla.
5) Distribute pudding into ramekins (or leave it in the bowl) and chill until it’s set, about 2-3 hours.