1. Preheat oven to 350 degrees Fahrenheit.
2. Press crust of choice into a pan (if using a crust), and set aside.
3. If coconut oil is not already in liquid form, gently warm it up until melted.
4. Add tofu, sugar, oil, vanilla, and salt to a food processor or blender. Then blend to achieve a thick and creamy filling.
5. Stir in the shredded coconut by hand.
6. Pour mixture into the prepared pie crust or a greased pie pan, and use a spatula to smooth the top.
7. Bake on the center rack of the oven for 30 minutes. Meanwhile, prepare the optional coconut whipped cream.
8. If you want to garnish your vegan coconut pie with toasted coconut, simply heat the coconut flakes in a skillet over medium heat for about 5 minutes.
9. Remove the pie from the oven, and let cool. Top with coconut whipped cream and toasted coconut if desired.