https://github.com/lakshmichandrakala/go-parameterize
Go implementation of Ruby's String.parameterize
https://github.com/lakshmichandrakala/go-parameterize
go golang parameterize ror ruby ruby-on-rails string
Last synced: 10 days ago
JSON representation
Go implementation of Ruby's String.parameterize
- Host: GitHub
- URL: https://github.com/lakshmichandrakala/go-parameterize
- Owner: lakshmichandrakala
- License: gpl-3.0
- Created: 2018-07-17T04:54:31.000Z (almost 8 years ago)
- Default Branch: master
- Last Pushed: 2019-03-11T03:31:37.000Z (over 7 years ago)
- Last Synced: 2024-11-15T05:51:53.534Z (over 1 year ago)
- Topics: go, golang, parameterize, ror, ruby, ruby-on-rails, string
- Language: Go
- Size: 16.6 KB
- Stars: 1
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# go-parameterize
Go implementation of Ruby's string parameterize
Replaces contiguous special characters in a string with a '-' and converts all alphabets to lower case. When there are only special characters in the original string, the result of parameterize is an empty string.
Examples:
Parameterize("New York") // "new-york"
Parameterize("$#@") // ""
Parameterize("$#@1#$%") // "1"