Closed churchs19 closed 6 years ago
This is a great contribution, thanks!
Please don't check-in the package-lock.json though (it might be good to add it to the gitignore even) as I don't believe it has much value for libraries (as opposed to applications) and I use Yarn myself anyway :) Also, if you could minimize the diff to only code changes instead of including some indentation-only changes, that would be great. Then it should be good to merge!
I believe my latest update addresses all of your comments. Thanks for being open to the updates!
Great, thanks again!
FYI, I've published v1.2.1 which includes this PR to NPM as well. Cheers!
I updated the tests to check the
tag handling since that was incorrect as written.
I also added code to treat all HTML block level elements as new lines in order to make the maxLines parameter more meaningful when the truncated HTML content is displayed on-screen.