To make the gula melaka syrup, in a small saucepan on medium heat, dissolve the grated gula melaka with water. Add the pandan leaves for extra fragrance, if using. Once the sugar dissolves and the syrup starts to slowing bubble, turn off the heat and let it cool completely.