bsidelinger912 / shiitake

React Line clamp that won't get you fired
MIT License
100 stars 22 forks source link

How to know if the text is truncated ? #26

Closed BahaaZidan closed 5 years ago

BahaaZidan commented 5 years ago

First of all, let me thank you for the great component (you saved me a lot of time).

I was wondering if there's a supported way to determine if shiitake truncated it's children or not. (without messing around with the DOM)

I tried taking a ref and looking at the state. found allChildren, testChildren but it didn't help much.

bsidelinger912 commented 5 years ago

Hey @bahaa-al-deen, this is basically the same ask as with #25. I can see the need for this for sure, so I'll work on a solution ASAP.

bsidelinger912 commented 5 years ago

This release should give you what you need @bahaa-al-deen: https://github.com/bsidelinger912/shiitake/releases/tag/v2.3.0

BahaaZidan commented 5 years ago

thanks