Mangroves also trap and stabilise sediment and reduce the risk of shoreline erosion - which brings waves closer to habitation - by dissipating surface wave energy.