Guide to String Encoding in Ruby

1 · Aaron Patterson · Jan. 14, 2020, 12:15 a.m.
Encoding issues don’t seem to happen frequently, but that is a blessing and a curse. It’s great not to fix them very frequently, but when you do need to fix them, lack of experience can leave you feeling lost. This post is meant to be a sort of guide about what to do when you encounter different types of encoding errors in Ruby. First we’ll cover what an encoding object is, then we’ll look at common encoding exceptions and how to fix them. What are String encodings in Ruby? In Ruby, strings are ...