refactor parser, make parsing and toHtml SYNC, use transformers to do async stuff