Skip to content
/ casee Public

Golang liibrary for case convertion of string.

License

Notifications You must be signed in to change notification settings

pinzolo/casee

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

44 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

casee

Test Coverage Status Go Report Card Godoc license

Golang liibrary for case convertion of string.

Usage

  1. go get -d github.com/pinzolo/casee.
  2. Add github.com/pinzolo/casee to import section in your go file.

Functions

Convert functions

  • ToSnakeCase
    Convert to snake_case style string.
  • ToChainCase
    Convert to chain-case style string.
  • ToCamelCase
    Convert to camelCase style string.
  • ToPascalCase
    Convert to PascalCase style string.
  • ToFlatCase
    Convert to flatcase style string.
  • ToUpperCase
    Convert to UPPER_CASE style string.

Check functions

  • IsSnakeCase
    Check argument string is snake_case.
  • IsChainCase
    Check argument string is chain-case.
  • IsCamelCase
    Check argument string is camelCase.
  • IsPascalCase
    Check argument string is PascalCase.
  • IsFlatCase
    Check argument string is flatcase.
  • IsUpperCase
    Check argument string is UPPER_CASE.

If first character is digit, IsCamelCase, IsPascalCase and IsFlatCase always returns false.
Because cannot judge upper or lower.

About

Golang liibrary for case convertion of string.

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages