Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: adding Elipse #470

Merged
merged 1 commit into from
Jun 27, 2024
Merged

feat: adding Elipse #470

merged 1 commit into from
Jun 27, 2024

Conversation

samber
Copy link
Owner

@samber samber commented Jun 27, 2024

No description provided.

@samber samber merged commit e5e4f02 into master Jun 27, 2024
14 checks passed

// Elipse truncates a string to a specified length and appends an ellipsis if truncated.
func Elipse(str string, length int) string {
if len(str) > length {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
if len(str) > length {
if len(str) <= length {
return str
}
if len(str) < 3 || length < 3 {
return "..."
}
return str[0:length-3] + "..."

github-actions bot referenced this pull request in kairos-io/provider-kairos Jun 27, 2024
[![Mend
Renovate](https://app.renovatebot.com/images/banner.svg)](https://renovatebot.com)

This PR contains the following updates:

| Package | Change | Age | Adoption | Passing | Confidence |
|---|---|---|---|---|---|
| [github.com/samber/lo](https://togithub.com/samber/lo) | `v1.39.0` ->
`v1.41.0` |
[![age](https://developer.mend.io/api/mc/badges/age/go/github.com%2fsamber%2flo/v1.41.0?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|
[![adoption](https://developer.mend.io/api/mc/badges/adoption/go/github.com%2fsamber%2flo/v1.41.0?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|
[![passing](https://developer.mend.io/api/mc/badges/compatibility/go/github.com%2fsamber%2flo/v1.39.0/v1.41.0?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|
[![confidence](https://developer.mend.io/api/mc/badges/confidence/go/github.com%2fsamber%2flo/v1.39.0/v1.41.0?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|

---

### Release Notes

<details>
<summary>samber/lo (github.com/samber/lo)</summary>

### [`v1.41.0`](https://togithub.com/samber/lo/releases/tag/v1.41.0)

[Compare
Source](https://togithub.com/samber/lo/compare/v1.40.0...v1.41.0)

#### What's Changed

- feat: adding Elipse by [@&#8203;samber](https://togithub.com/samber)
in
[https://github.com/samber/lo/pull/470](https://togithub.com/samber/lo/pull/470)
- feat: adding CoalesceOrEmpty by
[@&#8203;samber](https://togithub.com/samber) in
[https://github.com/samber/lo/pull/469](https://togithub.com/samber/lo/pull/469)
- feat: adding Earliest and Latest by
[@&#8203;samber](https://togithub.com/samber) in
[https://github.com/samber/lo/pull/468](https://togithub.com/samber/lo/pull/468)
- feat: adding duration by [@&#8203;samber](https://togithub.com/samber)
in
[https://github.com/samber/lo/pull/471](https://togithub.com/samber/lo/pull/471)
- feat: adding FilterReject by
[@&#8203;samber](https://togithub.com/samber) in
[https://github.com/samber/lo/pull/472](https://togithub.com/samber/lo/pull/472)
- feat: adding RejectMap by
[@&#8203;samber](https://togithub.com/samber) in
[https://github.com/samber/lo/pull/473](https://togithub.com/samber/lo/pull/473)

**Full Changelog**:
samber/lo@v1.34.0...v1.41.0

### [`v1.40.0`](https://togithub.com/samber/lo/releases/tag/v1.40.0)

[Compare
Source](https://togithub.com/samber/lo/compare/v1.39.0...v1.40.0)

#### What's Changed

##### Improvements

- Use map indexing to speed up PickByKeys and OmitByKeys by
[@&#8203;ericleb010](https://togithub.com/ericleb010) in
[https://github.com/samber/lo/pull/447](https://togithub.com/samber/lo/pull/447)
- ToSlicePtr: reduce allocations and improving speed by
[@&#8203;yanmhlv](https://togithub.com/yanmhlv) in
[https://github.com/samber/lo/pull/465](https://togithub.com/samber/lo/pull/465)
- Feat: Adding zipby + unzipby by
[@&#8203;samber](https://togithub.com/samber) in
[https://github.com/samber/lo/pull/449](https://togithub.com/samber/lo/pull/449)
- feat: add string conversion functions by
[@&#8203;eiixy](https://togithub.com/eiixy) in
[https://github.com/samber/lo/pull/466](https://togithub.com/samber/lo/pull/466)
- Adding Mean and MeanBy by
[@&#8203;usman1100](https://togithub.com/usman1100) in
[https://github.com/samber/lo/pull/414](https://togithub.com/samber/lo/pull/414)

##### Doc & style

- Fix typos by [@&#8203;szepeviktor](https://togithub.com/szepeviktor)
in
[https://github.com/samber/lo/pull/384](https://togithub.com/samber/lo/pull/384)
- fix: instantiate typo by
[@&#8203;testwill](https://togithub.com/testwill) in
[https://github.com/samber/lo/pull/374](https://togithub.com/samber/lo/pull/374)
- Fix typo in README.md by
[@&#8203;eltociear](https://togithub.com/eltociear) in
[https://github.com/samber/lo/pull/369](https://togithub.com/samber/lo/pull/369)
- docs: update description for FindOrElse by
[@&#8203;slomek](https://togithub.com/slomek) in
[https://github.com/samber/lo/pull/370](https://togithub.com/samber/lo/pull/370)
- style: no extra any type parameter by
[@&#8203;d-enk](https://togithub.com/d-enk) in
[https://github.com/samber/lo/pull/429](https://togithub.com/samber/lo/pull/429)
- Fix IsNil link for pkg.go.dev by
[@&#8203;invzhi](https://togithub.com/invzhi) in
[https://github.com/samber/lo/pull/418](https://togithub.com/samber/lo/pull/418)
- Docs: should use type int64 for lo.FlatMap in example by
[@&#8203;apriil15](https://togithub.com/apriil15) in
[https://github.com/samber/lo/pull/435](https://togithub.com/samber/lo/pull/435)

##### CI

- CI: tests on multi go versions by
[@&#8203;jiro4989](https://togithub.com/jiro4989) in
[https://github.com/samber/lo/pull/445](https://togithub.com/samber/lo/pull/445)

#### New Contributors

- [@&#8203;szepeviktor](https://togithub.com/szepeviktor) made their
first contribution in
[https://github.com/samber/lo/pull/384](https://togithub.com/samber/lo/pull/384)
- [@&#8203;testwill](https://togithub.com/testwill) made their first
contribution in
[https://github.com/samber/lo/pull/374](https://togithub.com/samber/lo/pull/374)
- [@&#8203;eltociear](https://togithub.com/eltociear) made their first
contribution in
[https://github.com/samber/lo/pull/369](https://togithub.com/samber/lo/pull/369)
- [@&#8203;slomek](https://togithub.com/slomek) made their first
contribution in
[https://github.com/samber/lo/pull/370](https://togithub.com/samber/lo/pull/370)
- [@&#8203;ericleb010](https://togithub.com/ericleb010) made their first
contribution in
[https://github.com/samber/lo/pull/447](https://togithub.com/samber/lo/pull/447)
- [@&#8203;yanmhlv](https://togithub.com/yanmhlv) made their first
contribution in
[https://github.com/samber/lo/pull/465](https://togithub.com/samber/lo/pull/465)
- [@&#8203;eiixy](https://togithub.com/eiixy) made their first
contribution in
[https://github.com/samber/lo/pull/466](https://togithub.com/samber/lo/pull/466)
- [@&#8203;jiro4989](https://togithub.com/jiro4989) made their first
contribution in
[https://github.com/samber/lo/pull/445](https://togithub.com/samber/lo/pull/445)
- [@&#8203;d-enk](https://togithub.com/d-enk) made their first
contribution in
[https://github.com/samber/lo/pull/429](https://togithub.com/samber/lo/pull/429)
- [@&#8203;usman1100](https://togithub.com/usman1100) made their first
contribution in
[https://github.com/samber/lo/pull/414](https://togithub.com/samber/lo/pull/414)
- [@&#8203;invzhi](https://togithub.com/invzhi) made their first
contribution in
[https://github.com/samber/lo/pull/418](https://togithub.com/samber/lo/pull/418)
- [@&#8203;apriil15](https://togithub.com/apriil15) made their first
contribution in
[https://github.com/samber/lo/pull/435](https://togithub.com/samber/lo/pull/435)

**Full Changelog**:
samber/lo@v1.39.0...v1.40.0

</details>

---

### Configuration

📅 **Schedule**: Branch creation - "after 11pm every weekday,before 7am
every weekday,every weekend" in timezone Europe/Brussels, Automerge - At
any time (no schedule defined).

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

♻ **Rebasing**: Whenever PR becomes conflicted, or you tick the
rebase/retry checkbox.

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

---

- [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check
this box

---

This PR has been generated by [Mend
Renovate](https://www.mend.io/free-developer-tools/renovate/). View
repository job log
[here](https://developer.mend.io/github/kairos-io/provider-kairos).

<!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiIzNy40MjAuMSIsInVwZGF0ZWRJblZlciI6IjM3LjQyMC4xIiwidGFyZ2V0QnJhbmNoIjoibWFpbiIsImxhYmVscyI6W119-->

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
codeboten referenced this pull request in open-telemetry/opentelemetry-collector-contrib Jul 2, 2024
[![Mend
Renovate](https://app.renovatebot.com/images/banner.svg)](https://renovatebot.com)

This PR contains the following updates:

| Package | Change | Age | Adoption | Passing | Confidence |
|---|---|---|---|---|---|
| [github.com/samber/lo](https://togithub.com/samber/lo) | `v1.39.0` ->
`v1.44.0` |
[![age](https://developer.mend.io/api/mc/badges/age/go/github.com%2fsamber%2flo/v1.44.0?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|
[![adoption](https://developer.mend.io/api/mc/badges/adoption/go/github.com%2fsamber%2flo/v1.44.0?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|
[![passing](https://developer.mend.io/api/mc/badges/compatibility/go/github.com%2fsamber%2flo/v1.39.0/v1.44.0?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|
[![confidence](https://developer.mend.io/api/mc/badges/confidence/go/github.com%2fsamber%2flo/v1.39.0/v1.44.0?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|

---

> [!WARNING]
> Some dependencies could not be looked up. Check the Dependency
Dashboard for more information.

---

### Release Notes

<details>
<summary>samber/lo (github.com/samber/lo)</summary>

### [`v1.44.0`](https://togithub.com/samber/lo/releases/tag/v1.44.0)

[Compare
Source](https://togithub.com/samber/lo/compare/v1.43.0...v1.44.0)

#### What's Changed

- feat: Add slice Splice an element or multiple elements at index i. by
[@&#8203;wenlingang](https://togithub.com/wenlingang) in
[https://github.com/samber/lo/pull/371](https://togithub.com/samber/lo/pull/371)
- feat: Make Filter() preserve type. by
[@&#8203;FGasper](https://togithub.com/FGasper) in
[https://github.com/samber/lo/pull/365](https://togithub.com/samber/lo/pull/365)
- feat: Added DropByIndex helper for slice by
[@&#8203;phith0n](https://togithub.com/phith0n) in
[https://github.com/samber/lo/pull/398](https://togithub.com/samber/lo/pull/398)
- feat: upgrade to math/rand/v2 by
[@&#8203;samber](https://togithub.com/samber) in
[https://github.com/samber/lo/pull/483](https://togithub.com/samber/lo/pull/483)
- chore: remove `golang.org/x/exp` since it doesn't follow go 1
compatibility promise by [@&#8203;trim21](https://togithub.com/trim21)
in
[https://github.com/samber/lo/pull/478](https://togithub.com/samber/lo/pull/478)

#### New Contributors

- [@&#8203;wenlingang](https://togithub.com/wenlingang) made their first
contribution in
[https://github.com/samber/lo/pull/371](https://togithub.com/samber/lo/pull/371)
- [@&#8203;jason-zhj](https://togithub.com/jason-zhj) made their first
contribution in
[https://github.com/samber/lo/pull/376](https://togithub.com/samber/lo/pull/376)
- [@&#8203;FGasper](https://togithub.com/FGasper) made their first
contribution in
[https://github.com/samber/lo/pull/365](https://togithub.com/samber/lo/pull/365)
- [@&#8203;phith0n](https://togithub.com/phith0n) made their first
contribution in
[https://github.com/samber/lo/pull/398](https://togithub.com/samber/lo/pull/398)

**Full Changelog**:
samber/lo@v1.43.0...v1.44.0

### [`v1.43.0`](https://togithub.com/samber/lo/releases/tag/v1.43.0)

[Compare
Source](https://togithub.com/samber/lo/compare/v1.42.0...v1.43.0)

#### What's Changed

- feat: adding HasKey by [@&#8203;samber](https://togithub.com/samber)
in
[https://github.com/samber/lo/pull/477](https://togithub.com/samber/lo/pull/477)
- feat: adding lo.WaitFor by
[@&#8203;samber](https://togithub.com/samber) in
[https://github.com/samber/lo/pull/269](https://togithub.com/samber/lo/pull/269)
- improvement: Optimize the performance of union method, avoid repeated
expansion by [@&#8203;cwb2819259](https://togithub.com/cwb2819259) in
[https://github.com/samber/lo/pull/397](https://togithub.com/samber/lo/pull/397)

#### New Contributors

- [@&#8203;cwb2819259](https://togithub.com/cwb2819259) made their first
contribution in
[https://github.com/samber/lo/pull/397](https://togithub.com/samber/lo/pull/397)

**Full Changelog**:
samber/lo@v1.42.0...v1.43.0

### [`v1.42.0`](https://togithub.com/samber/lo/releases/tag/v1.42.0)

[Compare
Source](https://togithub.com/samber/lo/compare/v1.41.0...v1.42.0)

#### What's Changed

- feat: add Nil by [@&#8203;gubtos](https://togithub.com/gubtos) in
[https://github.com/samber/lo/pull/383](https://togithub.com/samber/lo/pull/383)
- feat: Add First and FirstOrZeroValue functions by
[@&#8203;Alireza-Kiani](https://togithub.com/Alireza-Kiani) in
[https://github.com/samber/lo/pull/451](https://togithub.com/samber/lo/pull/451)
- feat: adding LastOrEmpty and LastOr by
[@&#8203;samber](https://togithub.com/samber) in
[https://github.com/samber/lo/pull/474](https://togithub.com/samber/lo/pull/474)
- feat: Feature/contains iterate by index by
[@&#8203;lennon-guan](https://togithub.com/lennon-guan) in
[https://github.com/samber/lo/pull/428](https://togithub.com/samber/lo/pull/428)
- feat: speed up loops by reducing allocations by
[@&#8203;samber](https://togithub.com/samber) in
[https://github.com/samber/lo/pull/475](https://togithub.com/samber/lo/pull/475)
- doc: inconsistent expression in README.md by
[@&#8203;rolancia](https://togithub.com/rolancia) in
[https://github.com/samber/lo/pull/406](https://togithub.com/samber/lo/pull/406)

#### New Contributors

- [@&#8203;gubtos](https://togithub.com/gubtos) made their first
contribution in
[https://github.com/samber/lo/pull/383](https://togithub.com/samber/lo/pull/383)
- [@&#8203;Alireza-Kiani](https://togithub.com/Alireza-Kiani) made their
first contribution in
[https://github.com/samber/lo/pull/451](https://togithub.com/samber/lo/pull/451)
- [@&#8203;rolancia](https://togithub.com/rolancia) made their first
contribution in
[https://github.com/samber/lo/pull/406](https://togithub.com/samber/lo/pull/406)
- [@&#8203;lennon-guan](https://togithub.com/lennon-guan) made their
first contribution in
[https://github.com/samber/lo/pull/428](https://togithub.com/samber/lo/pull/428)

**Full Changelog**:
samber/lo@v1.41.0...v1.42.0

### [`v1.41.0`](https://togithub.com/samber/lo/releases/tag/v1.41.0)

[Compare
Source](https://togithub.com/samber/lo/compare/v1.40.0...v1.41.0)

#### What's Changed

- feat: adding Elipse by [@&#8203;samber](https://togithub.com/samber)
in
[https://github.com/samber/lo/pull/470](https://togithub.com/samber/lo/pull/470)
- feat: adding CoalesceOrEmpty by
[@&#8203;samber](https://togithub.com/samber) in
[https://github.com/samber/lo/pull/469](https://togithub.com/samber/lo/pull/469)
- feat: adding Earliest and Latest by
[@&#8203;samber](https://togithub.com/samber) in
[https://github.com/samber/lo/pull/468](https://togithub.com/samber/lo/pull/468)
- feat: adding duration by [@&#8203;samber](https://togithub.com/samber)
in
[https://github.com/samber/lo/pull/471](https://togithub.com/samber/lo/pull/471)
- feat: adding FilterReject by
[@&#8203;samber](https://togithub.com/samber) in
[https://github.com/samber/lo/pull/472](https://togithub.com/samber/lo/pull/472)
- feat: adding RejectMap by
[@&#8203;samber](https://togithub.com/samber) in
[https://github.com/samber/lo/pull/473](https://togithub.com/samber/lo/pull/473)

**Full Changelog**:
samber/lo@v1.34.0...v1.41.0

### [`v1.40.0`](https://togithub.com/samber/lo/releases/tag/v1.40.0)

[Compare
Source](https://togithub.com/samber/lo/compare/v1.39.0...v1.40.0)

#### What's Changed

##### Improvements

- Use map indexing to speed up PickByKeys and OmitByKeys by
[@&#8203;ericleb010](https://togithub.com/ericleb010) in
[https://github.com/samber/lo/pull/447](https://togithub.com/samber/lo/pull/447)
- ToSlicePtr: reduce allocations and improving speed by
[@&#8203;yanmhlv](https://togithub.com/yanmhlv) in
[https://github.com/samber/lo/pull/465](https://togithub.com/samber/lo/pull/465)
- Feat: Adding zipby + unzipby by
[@&#8203;samber](https://togithub.com/samber) in
[https://github.com/samber/lo/pull/449](https://togithub.com/samber/lo/pull/449)
- feat: add string conversion functions by
[@&#8203;eiixy](https://togithub.com/eiixy) in
[https://github.com/samber/lo/pull/466](https://togithub.com/samber/lo/pull/466)
- Adding Mean and MeanBy by
[@&#8203;usman1100](https://togithub.com/usman1100) in
[https://github.com/samber/lo/pull/414](https://togithub.com/samber/lo/pull/414)

##### Doc & style

- Fix typos by [@&#8203;szepeviktor](https://togithub.com/szepeviktor)
in
[https://github.com/samber/lo/pull/384](https://togithub.com/samber/lo/pull/384)
- fix: instantiate typo by
[@&#8203;testwill](https://togithub.com/testwill) in
[https://github.com/samber/lo/pull/374](https://togithub.com/samber/lo/pull/374)
- Fix typo in README.md by
[@&#8203;eltociear](https://togithub.com/eltociear) in
[https://github.com/samber/lo/pull/369](https://togithub.com/samber/lo/pull/369)
- docs: update description for FindOrElse by
[@&#8203;slomek](https://togithub.com/slomek) in
[https://github.com/samber/lo/pull/370](https://togithub.com/samber/lo/pull/370)
- style: no extra any type parameter by
[@&#8203;d-enk](https://togithub.com/d-enk) in
[https://github.com/samber/lo/pull/429](https://togithub.com/samber/lo/pull/429)
- Fix IsNil link for pkg.go.dev by
[@&#8203;invzhi](https://togithub.com/invzhi) in
[https://github.com/samber/lo/pull/418](https://togithub.com/samber/lo/pull/418)
- Docs: should use type int64 for lo.FlatMap in example by
[@&#8203;apriil15](https://togithub.com/apriil15) in
[https://github.com/samber/lo/pull/435](https://togithub.com/samber/lo/pull/435)

##### CI

- CI: tests on multi go versions by
[@&#8203;jiro4989](https://togithub.com/jiro4989) in
[https://github.com/samber/lo/pull/445](https://togithub.com/samber/lo/pull/445)

#### New Contributors

- [@&#8203;szepeviktor](https://togithub.com/szepeviktor) made their
first contribution in
[https://github.com/samber/lo/pull/384](https://togithub.com/samber/lo/pull/384)
- [@&#8203;testwill](https://togithub.com/testwill) made their first
contribution in
[https://github.com/samber/lo/pull/374](https://togithub.com/samber/lo/pull/374)
- [@&#8203;eltociear](https://togithub.com/eltociear) made their first
contribution in
[https://github.com/samber/lo/pull/369](https://togithub.com/samber/lo/pull/369)
- [@&#8203;slomek](https://togithub.com/slomek) made their first
contribution in
[https://github.com/samber/lo/pull/370](https://togithub.com/samber/lo/pull/370)
- [@&#8203;ericleb010](https://togithub.com/ericleb010) made their first
contribution in
[https://github.com/samber/lo/pull/447](https://togithub.com/samber/lo/pull/447)
- [@&#8203;yanmhlv](https://togithub.com/yanmhlv) made their first
contribution in
[https://github.com/samber/lo/pull/465](https://togithub.com/samber/lo/pull/465)
- [@&#8203;eiixy](https://togithub.com/eiixy) made their first
contribution in
[https://github.com/samber/lo/pull/466](https://togithub.com/samber/lo/pull/466)
- [@&#8203;jiro4989](https://togithub.com/jiro4989) made their first
contribution in
[https://github.com/samber/lo/pull/445](https://togithub.com/samber/lo/pull/445)
- [@&#8203;d-enk](https://togithub.com/d-enk) made their first
contribution in
[https://github.com/samber/lo/pull/429](https://togithub.com/samber/lo/pull/429)
- [@&#8203;usman1100](https://togithub.com/usman1100) made their first
contribution in
[https://github.com/samber/lo/pull/414](https://togithub.com/samber/lo/pull/414)
- [@&#8203;invzhi](https://togithub.com/invzhi) made their first
contribution in
[https://github.com/samber/lo/pull/418](https://togithub.com/samber/lo/pull/418)
- [@&#8203;apriil15](https://togithub.com/apriil15) made their first
contribution in
[https://github.com/samber/lo/pull/435](https://togithub.com/samber/lo/pull/435)

**Full Changelog**:
samber/lo@v1.39.0...v1.40.0

</details>

---

### Configuration

📅 **Schedule**: Branch creation - "on tuesday" (UTC), Automerge - At any
time (no schedule defined).

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

♻ **Rebasing**: Whenever PR becomes conflicted, or you tick the
rebase/retry checkbox.

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

---

- [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check
this box

---

This PR has been generated by [Mend
Renovate](https://www.mend.io/free-developer-tools/renovate/). View
repository job log
[here](https://developer.mend.io/github/open-telemetry/opentelemetry-collector-contrib).

<!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiIzNy40MjEuMCIsInVwZGF0ZWRJblZlciI6IjM3LjQyMS4wIiwidGFyZ2V0QnJhbmNoIjoibWFpbiIsImxhYmVscyI6WyJkZXBlbmRlbmNpZXMiLCJyZW5vdmF0ZWJvdCJdfQ==-->

---------

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: opentelemetrybot <107717825+opentelemetrybot@users.noreply.github.com>
Co-authored-by: Yang Song <songy23@users.noreply.github.com>
@NathanBaulch
Copy link
Contributor

NathanBaulch commented Aug 15, 2024

Curious - why the name "Elipse" vs "Ellipsis" @samber?
This apparent typo drew my attention to this function, but while I'm here... FWIW I generally don't use it because:

  1. I prefer to append the more compact U+2026 now that Unicode is ubiquitous.
  2. I like to trim trailing whitespace after truncation to ensure the ellipsis isn't floating.

@ccoVeille
Copy link
Contributor

I would say it's because Samuel is French (as I do) and because Elipse is the word for Ellipsis in French.

I think it's a typo

@samber
Copy link
Owner Author

samber commented Aug 18, 2024

Oopsie. I'm going to fix that. 😅

@samber samber deleted the feat-adding-elipse branch August 18, 2024 14:36
@samber
Copy link
Owner Author

samber commented Aug 18, 2024

I added a trim to the helper as well.

Opening an issue to discuss about the U+2026 char.

@NathanBaulch
Copy link
Contributor

NathanBaulch commented Aug 18, 2024

Sorry, I should have explained "floating" ellipsis better above - I meant trimming after truncation to avoid this scenario:

is.Equal("hello...", Ellipsis("hello world", 9))
expected: "hello..."
actual  : "hello ..."

@samber
Copy link
Owner Author

samber commented Aug 18, 2024

ok, I made another fix

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.

3 participants