react-truncated-component

1.0.5 • Public • Published

React component to truncate your text with format and paragraphs support included.

NPM Build

Install

npm install --save react-truncated-component

Usage

function TruncatedText() {
  return (
    <ReactTruncatedComponent ellipsis="..." numberOfLines={5} lineHeight={23}>
      <p>{/*


    put your long text right here


    */}</p>
    </ReactTruncatedComponent>
  );
}

Docs

To see the documentation visit the website.

License

MIT © Juan Garcia

Readme

Keywords

none

Package Sidebar

Install

npm i react-truncated-component

Weekly Downloads

1,460

Version

1.0.5

License

MIT

Unpacked Size

99.7 kB

Total Files

6

Last publish

Collaborators

  • juangl