Remember the time when there were no cars on the island? That was due to a law that prohibited cars on the island.
By not allowing any cars, the residents prevented car accidents from occurring.
In this case, the risk of a car accident depended upon the presence of a specific risk factor: cars.
It is not hard to imagine that long before cars were allowed on the island, the residents taught their children that cars were dangerous, caused pollution, etc., etc. so that when cars did arrive on the island, they would stay safe.
The above measures would fall under “Primordial prevention”: employing preventive measures in the absence of the risk factor itself.