Preheat the oven to 350°F (180°C). Line an 8-inch square cake pan with parchment paper. Oil the sides and bottom of the parchment paper and pan. Set aside.
In a large mixing bowl, whisk self-rising flour, ground pistachios, cinnamon, ginger, and sugar.
Fold in the crushed pineapple, oil, coconut milk, unsweetened desiccated coconut, and vanilla.
Stir with a rubber spatula to incorporate.
If using, fold in the finely chopped medjool dates.
Pour the batter in the prepared pan.
Sprinkle extra chopped pistachios evenly on top.
Bake the cake at 350°F (180°C) for 50-60 minutes. Check if the cake is ready by inserting a toothpick in the center of the cake. If it comes out clean, it's ready to remove from the oven. If not, bake longer, in 10-minute increments, until the crumb is set.
Let it cool down in the pan for 10 minutes, then on a cooling rack at room temperature for 20 minutes before slicing.
