status-go/vendor/github.com/anacrolix/missinggo/strcase.go

12 lines
172 B
Go
Raw Permalink Normal View History

2022-03-10 09:44:48 +00:00
package missinggo
import (
"strings"
"github.com/huandu/xstrings"
)
func KebabCase(s string) string {
return strings.Replace(xstrings.ToSnakeCase(s), "_", "-", -1)
}