corrected docblock
added support for comments
added method for registering tag handlers
some refactoring, updated public api and docs