Post-processors run on the text of the entire document after is has been serialized into a string. Postprocessors should be used to work with the text just before output. Usually, they are used add back sections that were extracted in a preprocessor, fix up outgoing encodings, or wrap the whole document.
Postprocessors are run after the ElementTree it converted back into text.
Each Postprocessor implements a
run method that takes a pointer to a
text string, modifies it as necessary and returns a text string.
Postprocessors must extend
Restore raw html to the document.
Iterate over html stash and restore html.
Check is block of HTML is block-level.
Restore valid entities