createDom: Simplifying function and input structure
createDom: renaming to makeDom and using the solution proposed by arschmitz