https://github.com/minodisk/caseconv
Converting cases.
https://github.com/minodisk/caseconv
string-utility
Last synced: 10 months ago
JSON representation
Converting cases.
- Host: GitHub
- URL: https://github.com/minodisk/caseconv
- Owner: minodisk
- License: mit
- Created: 2017-01-27T16:51:30.000Z (about 9 years ago)
- Default Branch: master
- Last Pushed: 2017-03-03T03:36:37.000Z (almost 9 years ago)
- Last Synced: 2025-02-10T22:48:27.691Z (about 1 year ago)
- Topics: string-utility
- Language: Go
- Size: 11.7 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# caseconv [ ](https://app.codeship.com/projects/198764) [](https://goreportcard.com/report/github.com/minodisk/caseconv) [](https://coveralls.io/github/minodisk/caseconv?branch=master) [](https://godoc.org/github.com/minodisk/caseconv) [](LICENSE)
Converting cases.
## Installation
```bash
go get github.com/minodisk/caseconv
```
## Usage
```go
caseconv.LowerCamelCase(`Obi-Wan "Ben" Kenobi`) // -> "obiWanBenKenobi"
caseconv.UpperCamelCase(`Obi-Wan "Ben" Kenobi`) // -> "ObiWanBenKenobi"
caseconv.SnakeCase(`Obi-Wan "Ben" Kenobi`) // -> "Obi_Wan_Ben_Kenobi"
caseconv.LowerSnakeCase(`Obi-Wan "Ben" Kenobi`) // -> "obi_wan_ben_kenobi"
caseconv.UpperSnakeCase(`Obi-Wan "Ben" Kenobi`) // -> "OBI_WAN_BEN_KENOBI"
caseconv.Hyphens(`Obi-Wan "Ben" Kenobi`) // -> "Obi-Wan-Ben-Kenobi"
caseconv.LowerHyphens(`Obi-Wan "Ben" Kenobi`) // -> "obi-wan-ben-kenobi"
caseconv.UpperHyphens(`Obi-Wan "Ben" Kenobi`) // -> "OBI-WAN-BEN-KENOBI"
```