Rails has support for working with Unicode characters using the ActiveSupport multibyte chars functionality.
Chars in ActiveSupport had their own implementation for
Rails 6 deprecated below methods in ActiveSupport in favor of using String methods directly.
Unicode#downcase/upcase/swapcase in favor of
Unicode#normalize, Chars#normalize in favor of
Chars.consumes? in favor of
These String methods are available from Ruby 2.3+ onwards and hence they are delegated to Ruby Strings.
Before Rails 6
In Rails 6
Executing the above methods in Rails 6 will issue
as seen below: