Golang string manipulation package
Split the provided string into its parts and join them with the provided delimiter
strman.ToDelimited("fromCamel", ".") // from.camel
strman.ToDelimited("FromPascal", ".") // from.pascal
strman.ToDelimited("from-kebab", ".") // from.kebab
strman.ToDelimited("from_snake", ".") // from.snake
strman.ToDelimited("from-superMixed_case", ".") // from.super.mixed.case
Split the provided string into its parts, make them all uppercase, and join them with the provided delimiter
strman.ToDelimited("fromCamel", ".") // FROM.CAMEL
strman.ToDelimited("FromPascal", ".") // FROM.PASCAL
strman.ToDelimited("from-kebab", ".") // FROM.KEBAB
strman.ToDelimited("from_snake", ".") // FROM.SNAKE
strman.ToDelimited("from-superMixed_case", ".") // FROM.SUPER.MIXED.CASE
Run ToDelimited
with "_"
as the delimiter
strman.ToSnake("fromCamel") // from_camel
strman.ToSnake("from-kebab") // from_kebab
Run ToScreamingDelimited
with "_"
as the delimiter
strman.ToScreamingSnake("fromCamel") // FROM_CAMEL
strman.ToScreamingSnake("from-kebab") // FROM_KEBAB
Run ToDelimited
with "-"
as the delimiter
strman.ToKebab("fromCamel") // from-camel
strman.ToKebab("from_snake") // from-snake
Run ToScreamingDelimited
with "-"
as the delimiter
strman.ToScreamingKebab("fromCamel") // FROM-CAMEL
strman.ToScreamingKebab("from_snake") // FROM-SNAKE
Split the provided string into its parts and join them by capitalizing the first letter of each word
strman.ToPascal("fromCamel") // FromCamel
strman.ToPascal("from-kebab") // FromKebab
strman.ToPascal("from_snake") // FromSnake
Like ToPascal
but the first letter remains lowercase
strman.ToCamel("FromPascal") // fromPascal
strman.ToCamel("from-kebab") // fromKebab
strman.ToCamel("from_snake") // fromSnake