Last active
March 18, 2020 06:36
-
-
Save richardsondx/d2b2fb666bfd56a726c67840d7a9180a to your computer and use it in GitHub Desktop.
Humanize Method
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class String | |
# ..... some code | |
# | |
# See ActiveSupport::Inflector.humanize. | |
def humanize(capitalize: true, keep_id_suffix: false) | |
ActiveSupport::Inflector.humanize(self, capitalize: capitalize, keep_id_suffix: keep_id_suffix) | |
end | |
# .... more codee | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment