WordPress 5.5 – ReferenceError: commonL10n is not defined error

This is Trac ticket 51223:

commonL10n and other JS globals removed without backwards compatibility

In WordPress 5.5, the localized translations under commonL10n were replaced by wp.i18n.__ without deprecation notice or backwards compatibility. Plugins using commonL10n now have JavaScript errors introduced by updating WordPress which can break site functionality.

It was fixed in 5.5.1 by adding a compatibility layer. The best fix is to upgrade to 5.5.1.

commonL10n is still deprecated, however, and will be removed in 5.7.

Leave a Comment