Before making the cake batter, make sure all the ingredients are at room temperature.
Grease a 9-inch cake tin and line the bottom with baking parchment.
Arrange the pineapple slices close to each other. Spoon some (not all) of the butter-sugar syrup over the fruit. Set aside.
Preheat the oven to 175°C.
In a stand mixer or using a hand mixer, cream the butter and sugar till light and fluffy. Beat for around 3 minutes.
Beat in the egg and yolks one at a time.
Scrape down the egg mixture using a rubber spatula, and mix in the vanilla extract and the coconut along with the milk it has been soaking in.
Finally, gently fold in the flour taking care not to over-mix or use a heavy hand.
Pour the batter over the pineapple slices in the tin and tap the tin gently a few times to get rid of any air pockets.
Bake the cake for 40-50 minutes till a skewer inserted into the cake come out clean without any wet batter sticking to it. Turn off the upper element of your oven and cook the cake for a further 5-7 minutes.
Then, take the cake out of the oven and let it rest in the pan for 10 minutes before un-molding onto a plate or cake stand. Cool and serve with the leftover syrup or on its own.