Lost in Translations: Bringing the World to Shopify

Christian Blais
9 min readbeginner
--
View Original

Overview

The article discusses Shopify's efforts to enhance its platform for internationalization and localization, addressing challenges such as hardcoded strings and the need for a robust translation process. It outlines the strategies employed, including automated tooling, pseudolocalization, and the development of a Translation Platform to streamline collaboration between developers and translators.

What You'll Learn

1

How to implement automated tooling to detect hardcoded strings in a codebase

2

Why pseudolocalization is essential for visual testing in internationalization

3

How to build a Translation Platform that integrates with GitHub and translation management systems

Prerequisites & Requirements

  • Understanding of internationalization and localization concepts
  • Familiarity with GitHub and translation management systems(optional)

Key Questions Answered

What challenges does Shopify face in internationalizing its platform?
Shopify faces challenges such as hardcoded English strings, the need for automated tooling to detect violations, and ensuring that the platform accommodates various languages with different grammatical rules. These issues necessitate a comprehensive approach to refactor the codebase and streamline translation processes.
How does Shopify use pseudolocalization in its translation process?
Shopify employs pseudolocalization as a testing method to visualize how the UI will handle translations. By altering characters and doubling vowels, the team can simulate longer words from other languages, ensuring that the UI remains functional and aesthetically pleasing during the localization process.
What is the purpose of Shopify's Translation Platform?
The Translation Platform serves as an internal tool that automates the translation request process between developers and translators. By integrating with GitHub and translation management systems, it streamlines collaboration and ensures that translation updates are efficiently managed and tracked.
What issues arise from using MySQL's default character set for internationalization?
MySQL's default utf8 character set only supports up to three bytes per code point, limiting the ability to store certain characters like emojis and hentaigana. This necessitates migration to a proper UTF-8 setup to fully support internationalization needs.

Key Statistics & Figures

Number of businesses powered by Shopify
over 600,000
This highlights the scale at which Shopify operates and the importance of effective internationalization.
Number of countries Shopify operates in
approximately 175
This statistic underscores the need for a localized experience across diverse markets.

Technologies & Tools

Some links below are affiliate links. We may earn a commission if you make a purchase.

Database
Mysql
Used for storing data, but requires migration to support proper UTF-8 character sets for internationalization.
Backend
Rails I18n
The framework used for internationalization in Shopify's applications.

Key Actionable Insights

1
Implement automated tooling to detect hardcoded strings in your codebase to facilitate internationalization.
By using linters and automated checks, developers can prevent the introduction of new hardcoded strings, making future translations easier and more efficient.
2
Utilize pseudolocalization to test UI elements for internationalization readiness.
This approach allows teams to identify potential layout issues caused by longer translations before actual localization occurs, ensuring a smoother transition.
3
Develop a Translation Platform that integrates with existing development tools to streamline the translation process.
This can enhance collaboration between developers and translators, reducing the time and effort required for managing translation requests and updates.

Common Pitfalls

1
Failing to address hardcoded strings in the codebase can lead to ongoing translation challenges.
Without a proactive approach to refactoring, new hardcoded strings can continuously complicate the localization process, making it difficult to maintain a consistent user experience across languages.
2
Neglecting character set limitations can result in data loss or display issues.
Using MySQL's default utf8 character set without migration can lead to problems with storing and displaying certain characters, impacting the overall functionality of the platform in international markets.

Related Concepts

Internationalization
Localization
Pseudolocalization
Translation Management Systems