Answer the question
In order to leave comments, you need to log in
How to make beautiful and convenient HTML from HTML code written in one line using Python?
Hello! I have a python html code generator but it generates it in one line. Is there any algorithm in python that turns HTML code written in one line into usable and readable HTML? I've tried through the BeautifulSoup library and the prettify() method, but the code doesn't get any more readable.
Answer the question
In order to leave comments, you need to log in
That helped. However, the prettify() method gives code that is not quite readable (instead of tabs, 1 space, etc.)
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question