generated a name property and a children property from input data