You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Feature: Please add plain text output functionality #150
I highly recommend using html2text library on the .summary() output for that.
converter = HTML2Text()
converter.ignore_links = True
converter.ignore_emphasis = True
converter.body_width = 0
text = converter.handle(html)
return text
given that it's that easy and that different people need different rendering options, and the options might change over time and I would need to reflect them in the library interface, I'd like to leave it as is.
However, I might consider adding a simple version, for that you need just .text_content() in lxml.
Reacted by Yevgen Papernyk, Anton Alekseev and Gaston Morixe
Like .summary() but plain text instead of the .summary() html version.
E.g. as a new method or as an argument for the .summary() method.
That would be very useful for Natural Language Processing.