@hackage countable-inflections0.0.1
Countable Text Inflections
Categories
License
MIT
Maintainer
Brady Ouren <brady@andand.co>
Links
Versions
Installation
Dependencies (5)
- base >=4.6 && <4.10
- bytestring
- exceptions >=0.6 && <0.9
- pcre-light
- text >=0.2 && <1.3 Show all…
Dependents (5)
@hackage/ihp-graphql, @hackage/ihp, @hackage/acme-everything, @hackage/ihp-ide, @hackage/ihp-schema-compiler
Package Flags
dev
(off by default)
Turn on development settings.
Countable Inflections

λ: :t makeMatchMapping
[(RegexPattern, RegexReplace)] -> [Inflection]
λ: let mapping = makeMatchMapping [("(octop)us", "\1i")]
λ: pluralizeWith mapping "octopus"
"octopi"
Irregular (from singular to plural with no greater pattern)
λ: :t makeIrregularMapping
[(Singular, Plural)] -> [Inflection]
λ: let mapping = makeIrregularMapping [("zombie","zombies")]
λ: pluralizeWith mapping "zombie"
"zombies"
Uncountable (doesn't have a mapping, word stays the same) so it has the type:
[Text] -> [Inflection]
License
MIT - see the LICENSE file.