Added documentation + support for self-closing tags in createElement