scule icon indicating copy to clipboard operation
scule copied to clipboard

🧵 String Case Utils

Results 21 scule issues
Sort by recently updated
recently updated
newest added
trafficstars

Also moves to ESLint flat config using the helper function from the unjs config package. Note that `prefer-string-raw` is disabled since it incorrectly tries to lint string literal types.

Resolves #101 Ensures the first word is transformed to *Upper-first* regardless whether or not it's an exception word ``` titleCase('a-world') // Before 'a World' // After 'A world' ```

This PR contains the following updates: | Package | Change | Age | Adoption | Passing | Confidence | |---|---|---|---|---|---| | [pnpm](https://pnpm.io) ([source](https://redirect.github.com/pnpm/pnpm/tree/HEAD/pnpm)) | [`9.0.6` -> `10.7.0`](https://renovatebot.com/diffs/npm/pnpm/9.0.6/10.7.0) | [![age](https://developer.mend.io/api/mc/badges/age/npm/pnpm/10.7.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) |...

This PR contains the following updates: | Package | Change | Age | Adoption | Passing | Confidence | |---|---|---|---|---|---| | [unbuild](https://redirect.github.com/unjs/unbuild) | [`^2.0.0` -> `^3.5.0`](https://renovatebot.com/diffs/npm/unbuild/2.0.0/3.5.0) | [![age](https://developer.mend.io/api/mc/badges/age/npm/unbuild/3.5.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/unbuild/3.5.0?slim=true)](https://docs.renovatebot.com/merge-confidence/)...

### Describe the feature Hi @pi0, this library has been really useful, but it can be much more than that. It has got a very good foundation in terms of...

enhancement

Partially fixes #95 and #92 (marking as partial fixes as they also exhibit the issue in #101) Resolves #96 `splitByCase` has inconsistent behaviour when dealing with whitespaces. Adding whitespace as...

### Environment - [email protected] - [email protected] ### Reproduction ``` titleCase('in world') // actual: in World // expected: In World titleCase('and then') // actual: and Then // expected: And Then ```...

bug

fix #95 fix #92 I think for the `titleCase`, the `,` should not be took into account.

### Environment Any ### Reproduction ```ts import { titleCase } from 'scule' console.log(titleCase('Hello World')) // -> `Hello World` console.log(titleCase(titleCase('Hello World'))) // -> `Hello World` ``` ### Describe the bug It...

bug

### Environment NodeJS Safari Chrome FireFox ### Reproduction [Codesandbox](https://codesandbox.io/p/sandbox/4p7k4w) ### Describe the bug Casing is inconsistent. (see reproduction) ### Additional context _No response_ ### Logs _No response_

bug