Skip to content

Conversation

renovate[bot]
Copy link
Contributor

@renovate renovate bot commented Sep 12, 2024

This PR contains the following updates:

Package Change Age Confidence
truncate-html 1.0.4 -> 1.2.2 age confidence

Release Notes

oe/truncate-html (truncate-html)

v1.2.2

Compare Source

v1.2.1

Compare Source

v1.2.0: custom truncate strategy

Compare Source

A new option customNodeStrategy has been added. Check readme for details.

For your requirements, the following code may achieve your needs:

import truncate, { type IOptions, type ICustomNodeStrategy } from 'truncate-html'

// argument node is a cheerio instance
const customNodeStrategy: ICustomNodeStrategy = node => {
  // keep details and treat it as nothing inside
  if (node.is('details')) {
    return 'keep'
  }
}

const html = '<div><details><summary>Click me</summary><p>Some details</p></details>other things</div>'

const options: IOptions = {
  length: 3,
  customNodeStrategy
}

truncate(html, options)
// => <div><details><summary>Click me</summary><p>Some details</p></details>oth...</div>

ref: #​41

v1.1.2: Fix Cheerio's break changes

Compare Source

Cheerio released stable v1.0 a few days ago, but its APIs are very different from the latest beta version 1.0.0-rc.12, which breaks this lib.

The v1.1.2 release has pinned the cheerio version to 1.0.0-rc.12 to fix the cheerio problem.

Reference:

  1. Cheerio 1.0 released, batteries included 🔋
  2. cheerio#4024, more issues about cheerio

Cheerio spent years on beta version of 1.0, and then bring so many break changes in stable version? Unbelievable!

v1.1.1

Compare Source

v1.1.0: update cheerio to v1.0.0-rc.12

Compare Source

There are several changes:

  1. no vulnerabilities
    CleanShot 2023-06-17 at 20 37 48
  2. cheerio can now handle CJK characters correctly
  3. if you are using custom cheerio instance with this library, you should set the third parameter of cheerio.load to false to get rid of extra wrappers, see load for details.
  4. better support for typescript

Configuration

📅 Schedule: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined).

🚦 Automerge: Disabled by config. Please merge this manually once you are satisfied.

Rebasing: Whenever PR is behind base branch, or you tick the rebase/retry checkbox.

🔕 Ignore: Close this PR and you won't be reminded about this update again.


  • If you want to rebase/retry this PR, check this box

This PR was generated by Mend Renovate. View the repository job log.

Copy link

codecov bot commented Sep 12, 2024

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 90.83%. Comparing base (47b9a43) to head (ea1653d).
⚠️ Report is 1 commits behind head on master.

Additional details and impacted files
@@           Coverage Diff           @@
##           master    #1475   +/-   ##
=======================================
  Coverage   90.83%   90.83%           
=======================================
  Files         344      344           
  Lines        5794     5794           
  Branches     1374     1374           
=======================================
  Hits         5263     5263           
+ Misses        514      512    -2     
- Partials       17       19    +2     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@renovate renovate bot force-pushed the renovate/truncate-html-1.x branch 9 times, most recently from 33b922e to 90202b0 Compare September 19, 2024 16:57
@renovate renovate bot force-pushed the renovate/truncate-html-1.x branch 9 times, most recently from ecfce68 to 3e3841e Compare September 23, 2024 19:16
@renovate renovate bot force-pushed the renovate/truncate-html-1.x branch 3 times, most recently from d6a0fd8 to 8991202 Compare October 3, 2024 21:38
@renovate renovate bot force-pushed the renovate/truncate-html-1.x branch 3 times, most recently from 17506c8 to c1288e7 Compare October 11, 2024 09:42
@renovate renovate bot force-pushed the renovate/truncate-html-1.x branch 2 times, most recently from 5efb3fe to bb19e39 Compare October 21, 2024 18:09
@renovate renovate bot force-pushed the renovate/truncate-html-1.x branch 3 times, most recently from 1b65b94 to 6e7fca5 Compare October 28, 2024 14:33
@renovate renovate bot force-pushed the renovate/truncate-html-1.x branch 8 times, most recently from 9902a16 to b80cadd Compare August 4, 2025 14:38
@renovate renovate bot force-pushed the renovate/truncate-html-1.x branch from b80cadd to 5eb0730 Compare August 6, 2025 11:15
@renovate renovate bot force-pushed the renovate/truncate-html-1.x branch 2 times, most recently from f05443c to 9b4680e Compare August 18, 2025 00:45
@renovate renovate bot force-pushed the renovate/truncate-html-1.x branch 4 times, most recently from 65ca944 to 947c377 Compare August 25, 2025 16:55
@renovate renovate bot force-pushed the renovate/truncate-html-1.x branch 2 times, most recently from aceed7f to a317023 Compare September 8, 2025 00:41
@renovate renovate bot force-pushed the renovate/truncate-html-1.x branch 3 times, most recently from 1a44206 to 140a2aa Compare September 18, 2025 11:21
@renovate renovate bot force-pushed the renovate/truncate-html-1.x branch 4 times, most recently from 1167895 to 757aac3 Compare September 29, 2025 00:41
@renovate renovate bot force-pushed the renovate/truncate-html-1.x branch 4 times, most recently from 1ac7b1d to 6eaed04 Compare October 8, 2025 13:50
@renovate renovate bot force-pushed the renovate/truncate-html-1.x branch from 6eaed04 to ea1653d Compare October 13, 2025 00:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

0 participants