To truly serve a global audience, every piece of an application’s user interface must be accessible in multiple languages. This is no small feat. Manually handling translations is time-consuming and error-prone, especially as the application scales.
Of course, connecting with a global audience requires more than just translating text; it demands a thoughtful localization strategy that adapts content to various languages and cultural nuances. This task is paramount for a company with a diverse global user base like Navan. But managing localization across a complex, evolving platform can be daunting.
By integrating a suite of advanced localization tools and automation solutions, Navan has streamlined the localization process. Here’s how we did it.
Localization involves adapting text based on cultural norms, idiomatic expressions, and technical requirements while maintaining consistency and quality. Here are some of the common challenges faced by global companies.
To tackle these challenges, Navan built a custom solution that leverages automation and collaboration tools to streamline the process. Here’s how we did it, step by step.
Just as a solid foundation is essential for building a house, Lokalise serves as the bedrock for Navan’s localization efforts.
Lokalise is a powerful TMS and localization platform that helps developers and localization managers handle translations efficiently. It provides a centralized interface for uploading and downloading translation files, version control, and additional features for collaboration and integration with other platforms.
Navan uses Lokalise as the central hub for all product translation-related activities. This includes uploading source files for translation, downloading translated files, managing translations in different languages, and glossary and Translation Memory management.
Like a house’s framework supports the structure, Navan’s custom Command Line Interface (CLI) supports and streamlines the localization process. This tool provides a set of commands that developers can use to upload and download translations, among other tasks, making the process more efficient and standardized across projects.
This decision to decouple our uploads and downloads from the existing continuous integration and continuous delivery (CI/CD) or project codebases allows our front-end teams the flexibility and standardization required to implement this automation based on their needs.
Some benefits include:
Here is the CLI API reference related to Lokalise commands:
Our CLI requires a configuration file for all commands which gives each command the context when performing a task. In this case, you can see there is a downloadConfig and uploadConfig property which is passed through to the Lokalise project.
To help with developer ease of use we created helper commands in project.json so our team can reference these commands.
These commands ensure that developers can quickly sync their translations with Lokalise and maintain up-to-date localization across all projects.
Just as a modern house benefits from a well-designed utility network that manages electricity, water, and other essential services, Navan’s localization process is enhanced by the automation capabilities provided by GitHub Actions. Navan set up a shared workflow that handles the extraction, upload, and download of translations; the process is triggered automatically by specific events such as new commits or scheduled runs.
Navan uses a shared repository to centralize all GitHub Actions via shared workflows, composite actions, and custom JS actions. This consolidation allows front-end teams to consume standard workflows, or CI building blocks which are governed and provide versioning to prevent breaking changes.
Below is an example of our consumer Github Action which is scheduled to run daily and uses the shared workflow which invokes the CLI under-the-hood.
By integrating Lokalise, a custom CLI, and GitHub Actions, Navan has created a robust localization system that saves time, reduces errors, and improves collaboration. This innovative and comprehensive approach ensures that as Navan grows, its localization process remains scalable and efficient, and provides a consistent and seamless experience for users worldwide.