1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40
|
# case_transform
Extraction of the key_transform abilities of ActiveModelSerializers
[](https://badge.fury.io/rb/case_transform)
[](https://travis-ci.org/NullVoxPopuli/case_transform)
[](https://codeclimate.com/repos/57dafbcc628330006c001312/feed)
[](https://codeclimate.com/repos/57dafbcc628330006c001312/coverage)
[](https://gemnasium.com/NullVoxPopuli/case_transform)
## Install
```ruby
gem 'case_transform'
```
or
```bash
gem install case_transform
```
## Usage
```ruby
require 'case_transform'
CaseTransform.camel_lower(value)
```
`value` can be any of Array, Hash, Symbol, or String.
Any other object type will just be returned.
### Transforms
| | Description |
| --- | --- |
| camel | PascalCase |
| camel_lower | camelCase |
| dash | dash-case |
| underscore | under_score |
| unaltered | pass through |
|