kebabcase: dmitri.shuralyov.com/text/kebabcase Index | Examples | Files

package kebabcase

import "dmitri.shuralyov.com/text/kebabcase"

Package kebabcase provides a parser for identifier names using kebab-case naming convention.

Reference: https://en.wikipedia.org/wiki/Naming_convention_(programming)#Multiple-word_identifiers.

Code:

fmt.Println(kebabcase.Parse("client-mutation-id").ToMixedCaps())

Output:

ClientMutationID

Index

Examples

Package Files

kebabcase.go

func Parse Uses

func Parse(name string) ident.Name

Parse parses a kebab-case identifier name.

E.g., "client-mutation-id" -> {"client", "mutation", "id"}.

Package kebabcase imports 2 packages (graph). Updated 2019-05-13. Refresh now. Tools for package owners.