Localization / textdomain is slow and chaotic

In my opinion you are focusing on a wrong issue in this case.

For instance, if I want to change the Read More message I have to browse all files to see if it is there.

This doesn’t indicate localization problem. This indicates templating problem.

What if you want to change markup of Read More of whatever else? Do you have to do this in multiple places as well? Then it’s more about how templates are structured and duplication in them.

Not that WordPress is particularly good at that, but still worth a consideration.

Also I wonder about performance. For every page load WP loads the complete textdomain, only to find a translation that is always the same. Especially on the front end this doesn’t sound efficient.

You make a typical mistake of wondering instead of measuring.

There are certainly performance implications to localization in WordPress. However core already does plenty of it to load localization for itself.

If your theme doesn’t approach or exceed WP core in size of necessary translations then you are probably fine. If you want to be sure — profile performance and get sure. 🙂 Wondering just wastes your time on hypotheticals that might not need to be addressed.

Leave a Comment