refact almost done. addToDOM needs to be refact