Towns such as Castle Cary and Frome grew around the medieval weaving industry.