# How can I avoid my code being broken during translations?

**URL:** https://community.transifex.com/t/how-can-i-avoid-my-code-being-broken-during-translations/43
**Category:** Tips and Tricks
**Created:** [August 30, 2018, 4:25pm UTC](https://community.transifex.com/t/how-can-i-avoid-my-code-being-broken-during-translations/43 "2018-08-30T16:25:38Z")
**Posts on this page:** 3
**Page:** 1

<div class="post-metadata">

### Author: ![flafich](https://yyz2.discourse-cdn.com/flex030/user_avatar/community.transifex.com/flafich/32/11_2.png) [@flafich](https://community.transifex.com/u/flafich)
#### Post date: [August 30, 2018, 4:25pm UTC](https://community.transifex.com/t/how-can-i-avoid-my-code-being-broken-during-translations/43/1 "2018-08-30T16:25:38Z")

</div>

Many times codes that are inside translatable strings are not preserved, and it will affect the integration. There are a few reasons why it might happen:  
1- Machine Translation - Google translator sometimes add spaces and break the code.  
2- Translators are not sure if it should be preserved.  
How can we prevent it to happen?

---

<div class="post-metadata">

### Author: ![flafich](https://yyz2.discourse-cdn.com/flex030/user_avatar/community.transifex.com/flafich/32/11_2.png) [@flafich](https://community.transifex.com/u/flafich)
#### Post date: [August 30, 2018, 4:28pm UTC](https://community.transifex.com/t/how-can-i-avoid-my-code-being-broken-during-translations/43/2 "2018-08-30T16:28:45Z")

</div>

The best way to solve it would be:  
1- Add [Translation Checks](https://docs.transifex.com/setup/setting-translation-checks) to make sure the Translator will preserve the code.  
2- Run a review process to make sure that strings translated by machine translator has the code preserved.

We are also working to delivery a translation check on demand feature that will help reviewers when translations were done automatically via Machine translation, API or file uploads. More info will be announced soon!

---

<div class="post-metadata">

### Author: ![gunchleoc](https://avatars.discourse-cdn.com/v4/letter/g/3ec8ea/32.png) [@gunchleoc](https://community.transifex.com/u/gunchleoc)
#### Post date: [June 5, 2019, 3:11pm UTC](https://community.transifex.com/t/how-can-i-avoid-my-code-being-broken-during-translations/43/3 "2019-06-05T15:11:30Z")

</div>

Do not present code to translators, period. Hide it behind placeholders. Translators are not programmers, and we have to work without syntax highlighting too 😉
