Background of the issue:
I am trying to improve page speed performance on zeetim.com. Our hosting support identified that the plugin sitepress-multilingual-cms sets a wp-wpml_current_language cookie on every page load, even for logged out users. They tested a filter provided by WPML called wpml_should_skip_saving_language_in_cookies, and when this filter returns true, caching works correctly and the site loads faster. They created an mu-plugin on our staging site to test this, and the cache starts working as expected when the cookie is not set. Link to a page where the issue can be seen: link nascosto
Symptoms:
The wpml_current_language cookie forces cache to be bypassed, which slows down page delivery. I expected full page caching for logged out visitors without the wpml_current_language cookie being set, so that performance is improved and cache hits are consistent.
Questions:
Can using the wpml_should_skip_saving_language_in_cookies filter cause other issues on multilingual sites?
What is the correct and recommended way to prevent WPML from always setting this cookie for logged out users?