node-html-to-text
node-html-to-text copied to clipboard
Convert video tags to links
Currently, node-html-to-text ignores video tags. This PR adds support for video tags similar to img tags.
So if a video is encountered in either of these formats, with a src attribute or source tag...
<video src="http://example.com/a.mp4">
<video>
<source src="http://example.com/a.mp4">
<video>
...it will output a bracketed link to the video:
[http://example.com/a.mp4]
It also adds an ignoreVideo option that works the same way as ignoreImage.
This would resolve issue #103.
My team is finding your library very useful. Thanks for creating it!
Thanks for your pull request. Before I can accept it I need some unit tests for the new feature. Please add some test cases to the test/html-to-text.js file.