Mix together the flour, salt, yeast and caster sugar.
In a separate bowl, mix milk, butter and water until combined.
Add the wets to the dry ingredients and knead until smooth and elastic. Place the dough in a slightly greased bowl and cover with clingfilm then leave to rise somewhere warm for a couple of hours.
In the meantime, add the chopped pineapple, water and sugar to a pan and cook gently until the pineapple has softened. Add the cornflour solution and carry on cooking until it's thickened up, then add the shot of rum (if using) and leave to cool.
Scatter the desiccated coconut onto a baking tray and bake for around five minutes until toasted, then pour into a bowl and whisk in the sugar.
Use a pair of electric whisks to whip the coconut cream to stiff peaks - it helps if the coconut cream is really cold.
Heat the oil to around 160°C/320°F.
Take your risen doughnut dough and divide into 6 equal neat balls. Leave them to rise for another 45 mins then fry in two batches for around three mins on each side.
Drain any excess oil from them and toss them in the coconut sugar then leave to cool.
Place the pineapple mix and whipped coconut in separate piping bags. Cut two holes in the side of the doughnut and pipe a good squeeze of each inside and you're ready!