PHPackages                             dashifen/case-changing-trait - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. dashifen/case-changing-trait

ActiveLibrary

dashifen/case-changing-trait
============================

A PHP trait that converts between common programming character cases.

1.0.1(5y ago)04.5k3MITPHPPHP &gt;= 7.4

Since Apr 7Pushed 5y ago1 watchersCompare

[ Source](https://github.com/dashifen/case-changing-trait)[ Packagist](https://packagist.org/packages/dashifen/case-changing-trait)[ RSS](/packages/dashifen-case-changing-trait/feed)WikiDiscussions main Synced 4w ago

READMEChangelogDependenciesVersions (3)Used By (3)

Case Changing Trait
===================

[](#case-changing-trait)

This trait can be included to provide case changing capabilities within other PHP packages. Currently, the trait can covert between:

- [Kebab case](https://www.theserverside.com/definition/Kebab-case)
- [Camel case](https://en.wikipedia.org/wiki/Camel_case)
- [Snake case](https://en.wikipedia.org/wiki/Snake_case)
- [Pascal case](https://techterms.com/definition/pascalcase)

Furthermore, each of those can be turned into some sort of more "human-readable" style. Thus, *kebab-case* would become *kebab case* or *Kebab Case* if you want it capitalized.

Usage
-----

[](#usage)

Each of the cases listed above can be converted into the other ones. Thus, kebab case can be converted to camel, snake, and Pascal cases as well as the human-readable format. The names of the methods to do so are:

1. kebabToCamelCase
2. kebabToSnakeCase
3. kebabToPascalCase
4. kebabToReadableCase

Each of the other cases have a similar set of methods. Wherever possible, work performed by methods within the Trait were re-used to do this work. So, to convert from snake to camel case, we first convert to kebab-case and then to camel case. While this my spend a few more microseconds calling methods, it almost eliminates repeated code.

Studly Case?
------------

[](#studly-case)

There are a series of methods referencing studly case in the Trait that are deprecated. Dash originally though that studly case and Pascal case were the same, but has since learned that studly case usually refers to random or frequent capital letters as in "lOoK OuT fOr ThAt RoCk" used for ironic or comedic effect. These methods should be avoided and will be removed in version two.

###  Health Score

28

—

LowBetter than 54% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity17

Limited adoption so far

Community12

Small or concentrated contributor base

Maturity53

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~0 days

Total

2

Last Release

1858d ago

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/8269?v=4)[David Dashifen Kees](/maintainers/dashifen)[@dashifen](https://github.com/dashifen)

---

Top Contributors

[![dashifen](https://avatars.githubusercontent.com/u/8269?v=4)](https://github.com/dashifen "dashifen (2 commits)")

### Embed Badge

![Health badge](/badges/dashifen-case-changing-trait/health.svg)

```
[![Health](https://phpackages.com/badges/dashifen-case-changing-trait/health.svg)](https://phpackages.com/packages/dashifen-case-changing-trait)
```

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
