react-ellipsify. It has the basic functionality you might expect (controls over amount of items to show, separator to use and so on).
This can be useful if you want to temporarily hide some content (good UX). It might be fun to add animations etc. later on if there is interest.
Compared to a jQuery version I developed earlier, it was much faster and more fun to develop the React one. There's less code and it's easier to understand. Only traversal code is complex but that cannot be avoided here. Have fun ellipsifying!