In a medium saucepan, combine the coconut milk, sugar, vanilla extract, and salt. Heat over medium heat, stirring occasionally, until the sugar is completely dissolved. Do not let it boil.
Remove the saucepan from heat and let the mixture cool to room temperature. If using lime juice, stir it in once the mixture has cooled.
If you want a textured sorbet, fold in the shredded coconut at this point.
Pour the mixture into an ice cream maker and churn according to the manufacturer’s instructions until it reaches a soft-serve consistency.
Transfer the sorbet to an airtight container and freeze for at least 4 hours or until firm.
Scoop and serve the sorbet in bowls or cones. Enjoy!