Truncate text by words
bevacqua opened this issue · 1 comments
bevacqua commented
Consider using trunc-text
instead of https://github.com/MaxArt2501/share-this/blob/master/src/sharers/twitter.js#L17, so that you don't get the last word butchered up when trying to share long bits of text.
MaxArt2501 commented
Thanks for the suggestion, Nicolás.
Although I don't consider the sharers provided by the package as a vital part of the library, I do intend to improve from being more than basic examples.
Your utility seems like a good match for the task. I'll see if this fits in the next update.