JSPM

Found 325 results for truncate html

truncate-html

Truncate HTML and Keep Tags

  • v1.2.2
  • 318.65
  • Published

truncatise

Truncate HTML based on characters, words or paragraphs. Has the ability to strip tags.

  • v0.0.8
  • 206.96
  • Published

text-clipper

Fast and correct clip functions for HTML and plain text.

  • v2.2.0
  • 204.61
  • Published

html-ellipsis

truncates a html string without messing up the tags

  • v2.0.16
  • 175.79
  • Published

htmlsave

HTML save string utilities

  • v3.0.0
  • 175.53
  • Published

downsize

Tag-safe truncation for HTML and XML. Works by word!

  • v0.0.8
  • 171.92
  • Published

shave

Shave is a javascript plugin that truncates multi-line text within a html element based on set max height

  • v5.1.0
  • 155.68
  • Published

jquery-expander

Expand and collapse HTML content

  • v2.0.2
  • 141.76
  • Published

chop-lines

A React component which truncates lines of HTML.

  • v1.15.7
  • 112.16
  • Published

downsize-cjs

Tag-safe truncation for HTML and XML. Works by word!

  • v1.1.2
  • 102.22
  • Published

excerpts

Excerpting text of given words or characters from HTML.

  • v0.0.3
  • 101.00
  • Published

cli-truncate

Truncate a string to a specific width in the terminal

  • v4.0.0
  • 96.14
  • Published

html-truncate-ts

TypeScript library for truncating HTML strings while preserving HTML tags and structure

  • v0.1.3
  • 93.40
  • Published

lodash.truncate

The lodash method `_.truncate` exported as a module.

  • v4.4.2
  • 91.73
  • Published

semver-truncate

Truncate a semver version: `1.2.3` → `1.2.0`

  • v3.0.0
  • 87.96
  • Published

line-clamp

Line clamp a DOM element in vanilla JavaScript

  • v1.0.0
  • 86.20
  • Published

killable

Keeps track of a server's open sockets so they can be destroyed at a moment's notice.

  • v1.0.1
  • 82.48
  • Published

truncate-escaped-html

Converts special characters in a string to the corresponding HTML entities, then truncates the resulting string carefully (HTML entities are not cut in the middle).

  • v1.0.0
  • 80.76
  • Published

html-truncator

truncate html to a specified length but maintain the structure

    • v1.0.17
    • 79.12
    • Published

    hast-util-truncate

    hast utility to truncate the tree to a certain number of characters

    • v2.0.0
    • 76.32
    • Published

    unicode-byte-truncate

    Unicode aware string truncation that given a max byte size will truncate the string to or just below that size

    • v1.0.0
    • 72.44
    • Published

    stringz

    Zero-dependency unicode-aware string tools

    • v2.1.0
    • 71.78
    • Published

    log-chopper

    truncates a log file

    • v1.0.2
    • 67.89
    • Published

    ellipsize

    Ellipsizes a string at the nearest whitespace character near the end of allowed length

    • v0.6.2
    • 65.92
    • Published

    react-truncate

    React component for truncating multi-line spans and adding an ellipsis

    • v2.4.0
    • 65.43
    • Published

    voca

    The ultimate JavaScript string library

    • v1.4.1
    • 64.32
    • Published

    untruncate-json

    Fix up the end of a partial JSON string to create valid JSON.

    • v0.0.1
    • 63.98
    • Published

    @ayonli/jsext

    A JavaScript extension package for building strong and modern applications.

    • v1.8.0
    • 62.65
    • Published

    ansi-truncate

    A tiny function for truncating a string that may contain ANSI escape sequences.

    • v1.4.0
    • 62.43
    • Published

    react-multiline-clamp

    React component that uses the css line clamping to truncate given text in specified lines.

    • v2.0.0
    • 59.73
    • Published

    tiny-truncate

    A tiny function for truncating a string which may containg ANSI escapes, with automatic terminal width detection.

    • v1.0.5
    • 59.12
    • Published

    dtrim

    A tool for trimming deep/lenghty javascript structures. Some potential usages are: debugging, logging or data sanitization.

    • v1.12.0
    • 57.00
    • Published

    ember-line-clamp

    An ember addon component that provides a line-clamp solution with see more/see less capabilities

    • v3.2.3
    • 56.30
    • Published

    @re-dev/react-truncate

    Provides `Truncate`, `MiddleTruncate` and `ShowMore` React components for truncating multi-line spans and adding an ellipsis.

    • v0.5.2
    • 56.22
    • Published

    vue3-truncate-html

    A simple Vue 3 component that's truncate your text.

    • v1.2.1
    • 54.40
    • Published

    utf8-binary-cutter

    truncate UTF-8 strings to a given binary size

    • v0.9.2
    • 54.37
    • Published

    react-truncate-list

    Truncate a list of elements with a symbol or component of your choice

    • v1.0.3
    • 53.40
    • Published

    vue-line-clamp

    A simple, fast and lightweight directive for truncating multi line texts using "cross-browser" CSS strategies.

    • v1.3.2
    • 50.49
    • Published

    fixed-width-string

    Terminal ANSI-aware string fit to fixed width

    • v2.0.0
    • 49.92
    • Published

    angular-ellipsis

    Angular directive to truncate multi-line text

    • v1.0.1
    • 49.69
    • Published

    line-truncation

    Line Truncation is a zero dependency tool that truncate text by user defined line number

    • v1.3.9
    • 48.27
    • Published

    mdast-excerpt

    Build an excerpt from a markdown AST

    • v0.0.10
    • 48.05
    • Published

    dotdotdot-js

    Dotdotdot is a javascript plugin for truncating multiple line content with an ellipsis.

    • v4.1.0
    • 47.12
    • Published

    ngx-line-truncation

    Ngx Line Truncation is line truncation implementation for Angular that truncate text by user defined line number.

    • v1.9.1
    • 46.95
    • Published

    smart-truncate

    A small library that truncates a string. It can insert or append an ellipsis at any desired position of the truncated result.

    • v1.0.1
    • 46.40
    • Published

    json-truncate

    A way to truncate a json object.

    • v3.0.0
    • 45.70
    • Published

    ellipsis-angular

    A simple ellipsis directive for Angular 15+ that cuts content and adds '…' character if HTML content is overflowed.

    • v1.1.4
    • 44.88
    • Published

    vue-line-clamp-3

    A vue 3 port of the original vue-line-clamp

    • v1.0.1
    • 44.64
    • Published

    read-smore

    A simple read more / read less feature in vanilla js

    • v2.5.1
    • 44.58
    • Published

    prototyped.js

    Common typescript ready prototypes available in both CommonJS and ECMAScript

    • v3.0.5
    • 43.91
    • Published

    ember-truncate

    A generic component used to truncate text to a specified number of lines.

    • v3.0.1
    • 43.18
    • Published

    ng-text-truncate

    Angular directive to truncate and expand text by it lenght

    • v1.0.0
    • 42.62
    • Published

    vue-truncate-collapsed

    A simple component that truncates your text and adds a 'Read More/Show Less' clickable.

    • v3.0.1
    • 42.42
    • Published

    cuttr

    Cuttr is a javascript / jQuery plugin that truncates multi-line string content with multiple truncation methods and custom ellipsis.

    • v1.4.3
    • 41.93
    • Published

    just-truncate

    truncate a string with a custom suffix

    • v2.2.0
    • 41.92
    • Published

    truncate.js

    Fast, intelligent Javascript text truncation

    • v1.1.2
    • 41.84
    • Published

    shorten-url

    omit parts of a url for friendlier display

    • v1.1.0
    • 41.67
    • Published

    react-truncate-inside

    React component for adding an ellipsis to the middle of a line of text.

    • v1.0.3
    • 40.62
    • Published

    ng2-truncate

    This package has been moved to [@yellowspot/ng-truncate](https://www.npmjs.com/package/@yellowspot/ng-truncate)

    • v1.3.17
    • 40.41
    • Published

    obj-walker

    Walk or map over objects in a depth-first preorder or postorder manner.

    • v2.4.0
    • 39.16
    • Published

    crop-url

    Truncate a url so that it doesn't appear so long visually

    • v4.0.1
    • 38.85
    • Published

    math-truncate

    Rounds a numeric value toward zero.

    • v1.0.0
    • 37.83
    • Published

    cirbuf

    A tiny and fast circular buffer

      • v1.0.2
      • 37.24
      • Published

      p2p-schema

      A set of utilities for managing Prisma database schemas, seeding, and maintenance operations for the Procure-to-Pay system

      • v1.0.126
      • 36.43
      • Published

      truncate-evenly

      Truncate strings in an array to the maximum total length evenly.

      • v1.0.3
      • 36.26
      • Published

      text-truncate-scroll

      A light-weight js utility that truncates overflowing text with ellipsis, and shows the text content on hover with a scroll effect.

      • v1.3.5
      • 35.26
      • Published

      react-read-more

      React component for truncating multi-line spans and adding an ellipsis

      • v1.0.0
      • 35.10
      • Published

      react-middle-truncate

      A React component for intelligently truncating text in the middle of the string.

      • v1.0.3
      • 34.73
      • Published

      procbay-schema

      A set of utilities for managing Prisma database schemas, seeding, and maintenance operations for the Procure-to-Pay system

      • v1.0.19
      • 33.99
      • Published

      trunkata

      Truncation utility which preserves HTML content and can truncate by lines.

      • v0.2.1
      • 33.70
      • Published

      trunk8

      trunk8 is an intelligent text truncation extension to jQuery

      • v0.0.1
      • 32.29
      • Published

      friendly-truncate

      Human-friendly truncation preferring word boundaries and the middle of the string.

      • v1.3.0
      • 32.04
      • Published

      @miedward/ngx-line-truncation

      Ngx Line Truncation is line truncation implementation for Angular that truncate text by user defined line number.

      • v2.0.1
      • 32.00
      • Published

      vue-truncate-read-more

      A Vue.js V3/2 plugin for truncating text with a 'Read More' button to expand the text.

      • v1.1.2
      • 31.97
      • Published

      @kuoruan/text-clamp

      Clamps an HTML element by adding ellipsis to it.

      • v1.1.1
      • 31.93
      • Published

      openai-tokens

      A service for calculating, managing, truncating openai prompt tokens

      • v2.3.6
      • 31.60
      • Published

      truncate-url

      Truncate a URL to a specific length

      • v2.1.0
      • 31.15
      • Published

      m-truncate

      `mTruncate` is a lightweight and customizable Angular directive for truncating text with support for tooltips. It allows you to truncate text based on width or a specified number of lines and display a tooltip when the full text is not visible.

        • v1.0.5
        • 31.09
        • Published

        vue3-line-clamp

        A simple, fast and lightweight vue 3 directive for truncating multi line texts.

        • v1.0.2
        • 30.66
        • Published

        truncate-markup-string

        Truncates a string to a charLimit, ignoring specified markup tags, with an optional "pretty" ellipsis ending.

        • v1.0.2
        • 30.46
        • Published

        eripusisu

        Text truncation library

        • v1.3.1
        • 29.86
        • Published

        react-truncated-chips

        A headless component to implement a truncated chips based on parent container/screen size for users! Small bundle size of 2.1kb but can create super powerful UI experiences with a simple-to-use API. ![](assets/chips-demo.gif)

        • v1.1.4
        • 29.58
        • Published

        truncate-strings

        Simple lib to truncate text with ellipsis

        • v1.0.4
        • 29.17
        • Published

        shrink-path

        Utility to shrink file paths to a given length.

        • v0.3.1
        • 28.65
        • Published

        ngx-cut

        Angular directives for cutting texts

        • v3.0.0
        • 28.36
        • Published

        react-width-control

        A React component for setting minimum width and maximum width

        • v1.1.3
        • 28.33
        • Published

        extra-fs

        Useful additions to inbuilt fs module.

        • v3.3.1
        • 28.06
        • Published

        txt

        Utilities for working with text.

        • v1.0.0
        • 28.01
        • Published

        to-width

        The essential building block for command line tables: truncate & pad strings to given width, taking care of wide characters, accents and ANSI colors

        • v1.2.1
        • 27.82
        • Published

        xrg-utils

        A modern collection of reusable utility functions for JavaScript and TypeScript, designed to simplify everyday development tasks.

        • v1.0.8
        • 27.30
        • Published

        truncate-element

        With this package, you can make any changes you want on the text. Don't worry about the framework. It is a custom element and is compatible with all JavaScript frameworks.

        • v2.4.1
        • 27.16
        • Published

        react-text-trim

        Custimizable text trimmer for react

        • v1.0.3
        • 27.05
        • Published

        @fiquu/shorten

        Shortens a string (truncate) optionally keeping whole words.

        • v1.0.7
        • 26.91
        • Published

        tty-truncate

        Truncate a string to the current text terminal width

        • v1.0.5
        • 25.88
        • Published

        dots

        Truncate string

        • v0.1.0
        • 25.16
        • Published

        advanced-pad

        Left and right string padding with advanced features.

        • v1.0.6
        • 24.69
        • Published

        string-toolkit-pro

        A TypeScript-ready string utility library.

          • v2.1.2
          • 24.46
          • Published

          short-numbers

          Make short numbers from long numbers

          • v0.1.1
          • 24.25
          • Published

          web-component-text-truncate

          A custom web component for truncating multi-line text using CSS line clamping, configurable via the number of lines to display.

            • v1.0.0
            • 24.23
            • Published

            tweet-truncator

            Truncate contents of tweet to 140 chars.

            • v3.0.2
            • 21.91
            • Published

            ng-text-truncate-2

            Angular directive to truncate and expand text by it length

            • v1.0.1
            • 21.73
            • Published

            react-text-expander

            TextExpander is a React component designed to manage long blocks of text that might need to be truncated for display purposes. With TextExpander, developers can easily set a limit on the number of characters initially displayed, providing a clean, condens

            • v1.0.0
            • 21.48
            • Published

            @hugoalh/string-overflow

            A module to truncate the string with the specify length; Safe with the emojis, URLs, and words.

            • v2.1.1
            • 21.34
            • Published

            @minga/text-clipper

            Fast and correct clip functions for HTML and plain text.

              • v1.2.2
              • 21.11
              • Published

              clampify

              Trims multi line text and adds ellipsis in the end of it

              • v1.2.1
              • 20.92
              • Published

              nor-fs

              Asynchronous file system library with chainable Q promises for Node.js

              • v1.0.0
              • 20.85
              • Published

              ngx-truncate-text

              This module is for shortening the text and also includes some useful features for text manipulation like finding hashtags, highlight words with favorite color and so on after version 1.0.0.

              • v3.0.0
              • 20.62
              • Published

              blogdownsize

              Tag-safe truncation for HTML and XML. Works by word!

              • v0.1.0
              • 20.57
              • Published

              truncate-stream

              stream which truncates input after N bytes

              • v1.0.2
              • 20.38
              • Published

              string-truncate

              Truncate a string with a custom separator in the middle (tru…ate), end (trunca…) or at any index (t…ncate).

              • v1.0.0
              • 20.25
              • Published

              string-formatter-js

              A collection of useful string formatting utilities

                • v1.0.0
                • 20.24
                • Published

                ngx-truncate

                truncate for strings angular5

                • v0.0.1
                • 20.09
                • Published

                typeorm-truncate-all

                It simplifies the process of resetting the database to a clean state during testing or development by executing a PostgreSQL query to truncate all tables with cascade.

                • v1.0.8
                • 20.05
                • Published

                @procbay/tenant-schema

                A set of utilities for managing Prisma database schemas, seeding, and maintenance operations for the Procure-to-Pay system.

                • v1.0.0
                • 19.81
                • Published

                truncated-list

                Create a list of items with truncating lines to the specified maximum number

                • v1.0.1
                • 19.79
                • Published

                simple-truncate

                Truncate text without cutting words off.

                  • v1.0.0
                  • 19.31
                  • Published

                  ng-custom-pipe

                  An Angular Library, that gives you a hussle free experience on data operation using pipes

                  • v1.2.1
                  • 19.19
                  • Published

                  rc-tc-ifn

                  React simple. Truncate text and tooltip if need (Hooks)

                  • v2.6.0
                  • 18.88
                  • Published

                  cod-string-magic

                  A powerful and lightweight npm library for string manipulation.

                  • v1.0.2
                  • 18.07
                  • Published

                  cutshort

                  CutShort is a javascript plugin to create multiline overflow ellipsis easy.

                  • v1.0.7
                  • 17.93
                  • Published

                  str_shorten

                  Shorten string by character length with word boundary supported

                  • v1.0.18
                  • 17.74
                  • Published

                  tablur

                  Easily create tables for your cli.

                  • v1.2.1
                  • 17.01
                  • Published

                  node-truncate-string

                  Truncates string with an ellipsis and preserves full word, if needed.

                  • v0.0.2
                  • 16.91
                  • Published

                  truncate-vue

                  VueJs to truncate string

                  • v0.0.2
                  • 15.56
                  • Published

                  twitter-utils

                  Twitter / tweet utils that I find myself reusing often.

                  • v0.4.1
                  • 15.51
                  • Published

                  angular2-truncate

                  A simple angular2 pipe which truncate strings.

                  • v0.1.3
                  • 14.57
                  • Published

                  react-description-box

                  Customizable React component that can shorten long text using str_shorten library for better display

                  • v1.0.1
                  • 13.81
                  • Published

                  truncatestring

                  A function to shorten strings with options.

                  • v2.2.0
                  • 13.44
                  • Published

                  json-truncator

                  A utility to truncate JSON arrays or objects.

                    • v1.0.3
                    • 13.26
                    • Published

                    auto-ellipsis

                    auto-ellipsis is a React component for truncation when content overlength.

                    • v1.3.0
                    • 13.16
                    • Published

                    text-clamp-for-vue3

                    A Vue 3 component for clamping text with customizable expand/collapse functionality

                    • v1.0.9
                    • 13.04
                    • Published

                    @tutorbook/dotdotdot-js

                    Dotdotdot is a javascript plugin for truncating multiple line content with an ellipsis.

                    • v4.0.12
                    • 12.58
                    • Published

                    react-truncatable

                    A React component that truncates text based on available space and supports multiline. Perfect for creating article previews, blog snippets, product card descriptions and many more.Compatible with Next 13

                    • v1.0.6
                    • 12.29
                    • Published

                    ng-text-truncate-patched

                    Angular directive to truncate and expand text by it length. forked from ng-text-truncate by Pavel Konan

                    • v1.0.1
                    • 11.96
                    • Published

                    react-row-ellipsis

                    The package will allow you to easily cut a text to the indicated amount of lines

                    • v2.1.2
                    • 11.83
                    • Published

                    snug-json

                    A lightweight library for intelligently truncating JSON data, making it more readable and manageable for humans.

                    • v0.0.6
                    • 11.47
                    • Published

                    doorgets-ng-truncate

                    Angular 10 (ngx) truncate module from Directire, Pipe and Service

                    • v2.0.2
                    • 11.17
                    • Published

                    @extra-fs/promises

                    Useful additions to inbuilt fs module {promises}.

                    • v3.1.4
                    • 11.17
                    • Published

                    triple-dots

                    Triple dots is a javascript plugin for truncating multiple line content with an ellipsis.

                    • v0.0.3
                    • 11.09
                    • Published

                    react-auto-truncate-box

                    A React component for automatically truncating text with an ellipsis and optional toggle functionality.

                      • v1.0.0
                      • 10.79
                      • Published

                      @annoyingmouse/wc-trim-middle

                      This web component was inspired by Chris Heilmann and does not trim strings that don’t fit the space at the end, but in the middle of the string

                      • v1.0.2
                      • 10.67
                      • Published

                      pan-lib

                      A lightweight library featuring a collection of small, versatile functions designed to streamline your development experience and enhance productivity.

                      • v1.7.2
                      • 10.49
                      • Published

                      cheese-log

                      A colorful logger with browser-/environment-dependent formatting possibilities, table printing, object depth limiting, string- and array-truncating, etc.

                      • v4.0.1
                      • 10.48
                      • Published

                      ellipsisis

                      Truncates text string at spaces, then adds ellipsis at the end.

                      • v1.0.2
                      • 10.46
                      • Published

                      vue-text-truncate

                      Vue component - Omits the text that exceeds the specified height

                      • v1.0.3
                      • 10.40
                      • Published

                      cut-string

                      Cut a string if too long. Support CJK(漢字) and emoji❤️.

                      • v1.0.3
                      • 10.06
                      • Published

                      text-truncator

                      Universal library that makes a lot of text truncated in a small parent container.

                      • v1.3.0
                      • 10.00
                      • Published

                      @azizbecha/strkit

                      strkit is a utility library offering a collection of essential string functions including validation, case conversion, truncation, and more. Ideal for both JavaScript and TypeScript developers to simplify string operations in their applications.

                      • v1.1.1
                      • 9.80
                      • Published

                      smart-url-responsive-link

                      Automatically shorten long URLs for mobile views and improve readability

                      • v1.0.4
                      • 9.55
                      • Published

                      upin-string-utils

                      A collection of utility functions for string operations

                      • v1.0.3
                      • 9.54
                      • Published

                      trnct

                      Truncate all specified vowels from given word unless it is the first character

                      • v1.0.0
                      • 9.54
                      • Published

                      awesome-string

                      The ultimate JavaScript string library

                      • v1.1.1
                      • 9.35
                      • Published

                      @text-middle-ellipsis/vue

                      Adaptively fits overflowing string of text to its parent HTML Element container by replacin middle of a string with any ellipsis character of your choice.

                      • v0.0.2
                      • 9.20
                      • Published

                      @cityads/react-truncate

                      React component for truncating multi-line spans and adding an ellipsis

                      • v3.0.0
                      • 9.02
                      • Published

                      limit-characters

                      Limit characters with different criteria

                      • v1.0.3
                      • 9.01
                      • Published

                      superbstring

                      Superbstring is a versatile JavaScript package that provides a comprehensive set of functions to manipulate strings for both frontend and backend applications.

                      • v2.1.2
                      • 8.65
                      • Published

                      trimcate

                      convert long text into a previewable short text with with a start length and an end length

                      • v1.0.2
                      • 8.49
                      • Published

                      pixel-width-truncate

                      Fits text to any width by secretly measuring it with an invisible element.

                      • v1.0.3
                      • 8.17
                      • Published

                      s3-empty-bucket

                      Library and CLI to quickly empty AWS S3 buckets.

                      • v1.0.0-alpha.8
                      • 8.10
                      • Published

                      limit-stream

                      A stream that truncates to a limit

                      • v2.0.0
                      • 7.85
                      • Published

                      react-native-truncation-text

                      A Text extension React Native component that includes onTruncationChange to enable reading more

                      • v1.0.0
                      • 7.85
                      • Published

                      custom-truncate

                      Javascript string truncate using custom method

                      • v0.9.3
                      • 7.77
                      • Published

                      string-truncator

                      Over-engineered string truncation for web UI's

                      • v2.0.18
                      • 7.76
                      • Published

                      @jonigata/retracker

                      Retracker is a development tool for Node.js that helps you manage and resume long-running processes.

                      • v0.0.7
                      • 7.76
                      • Published

                      transform-string

                      Transform any string using properties CSS like

                      • v0.0.1
                      • 7.56
                      • Published

                      jsweetman-react-truncate

                      React component for truncating multi-line spans and adding an ellipsis forked from https://github.com/One-com/react-truncate

                      • v2.1.8
                      • 7.45
                      • Published

                      ng-trunk8

                      angular fork of trunk8

                      • v0.2.2
                      • 7.45
                      • Published

                      shavette

                      Truncate text to a specified number of lines

                      • v1.1.0
                      • 7.33
                      • Published

                      dynamic-truncator

                      A Lightweight cross-browser helper library that enables you to truncate text by the dimensions of a given element.

                      • v1.0.5
                      • 7.01
                      • Published

                      truncate-x

                      Truncate a string to a maximum specified length.

                      • v4.1.2
                      • 6.83
                      • Published

                      smarter-truncate

                      A smart text truncation component for React with Tailwind CSS

                      • v0.0.4
                      • 6.74
                      • Published

                      ember-truncate-4elements

                      A generic component used to truncate text to a specified number of lines.

                      • v0.3.4
                      • 6.74
                      • Published