I need to add inflection rules for the Italian language in a Rails5 application.
So, I updated initializers/inflections.rbas follows.
ActiveSupport::Inflector.inflections(:it) do |inflect|
inflect.plural /^([\w]*)o/i, '\1i'
inflect.plural /^([\w]*)a/i, '\1e'
inflect.uncountable %w( attività )
end
But after restarting the server, the English rules are still used.
The locale is correctly set to :it(the user interface is correctly localized), but the words are alternated using English rules.
Do I have a way to include the rules that I defined?
thank
source
share